or a rotary encoder in a linear application. Either way, you need to figure out what the overall mechanical ratio is between the linear motion and the rotary motion.
You need to provide more information. The answer depends on a lot of things; how many pulses per revolution your encoder produces, what the encoder is actually reading (diameter of a gear, etc.).