I have the following data and what I want to do is

[(13, 'D'), (14, 'T'), (32, '6'), (45, 'T'), (47, '2'), (48, '0'), (49, '2'), (50, '0'), (51, 'T'), (53, '2'), (54, '0'), (13, 'A'), (14, 'T'), (32, '6'), (45, 'A'), (47, '2'), (48, '0'), (49, '2'), (50, '0'), (51, 'X')]


Is for each key count the instances of the value (a 1 string character). So I first did a map:

.map(lambda x: (x[0], [x[1], 1]))


Making it now a key/tuple of:

[(13, ['D', 1]), (14, ['T', 1]), (32, ['6', 1]), (45, ['T', 1]), (47, ['2', 1]), (48, ['0', 1]), (49, ['2', 1]), (50, ['0', 1]), (51, ['T', 1]), (53, ['2', 1]), (54, ['0', 1]), (13, ['A', 1]), (14, ['T', 1]), (32, ['6', 1]), (45, ['A', 1]), (47, ['2', 1]), (48, ['0', 1]), (49, ['2', 1]), (50, ['0', 1]), (51, ['X', 1])]


I just cant for the last part figure out how to for each key count the instances of that letter. For instance Key 13 will have 1 D and 1 A. While 14 will have 2 T's, etc. 


Question: Linearity of push forward $F_*$
Answer: It follows from the definition of a directional derivative. If $F_*$ is linear then 
$$F_*(\lambda X + \mu Y) = \lambda (F_*X) + \mu (F_*Y)$$

If we apply the definition that $(F_*X)(\operatorname{f}) := X(\operatorname{f} \circ F)$ then we find that

$$[F_*(\lambda X + \mu Y)](\operatorname{f}) = (\lambda X + \mu Y)(\operatorname{f} \circ F)$$

Any definition of a connection involves linearity. In otherwords, the fact that 

$$(\lambda X + \mu Y)(\operatorname{f} \circ F) = \lambda [X(\operatorname{f}\circ F)] + \mu [Y(\operatorname{f} \circ F)] $$

is part of the definition of a connection.  Again, applying the definition, we have

$$\lambda [X(\operatorname{f}\circ F)] + \mu [Y(\operatorname{f} \circ F)] = \lambda (F_*X) + \mu (F_*Y)$$

Have a quick look at this article for the general definition of a connection.