So two ways come to mind.
You either store the previous player position in a variable then compare it to the present position to find out if it is to the left or right. It's probably easier to push a new position into the array if it is different from the last tick. Then compare the first point in the array with the second.
You get the touch positions and compare those. If my understanding is correct while you are touching an array of touch positions are stored. So you could compare the last position with the previous again similar to the above.