You will see that position and velocity are out of phase, meaning that they reach corresponding values at different times. This of course makes sense for a pendulum. The initial velocity is zero and the initial position is maximum. Velocity increases as the pendulum falls, reaching its maximum as the position passes through zero. Velocity by the way is speed in a certain direction so when the direction of motion reverses, velocity changes algebraic sign + to - or - to +.