By definition we have to:

Where,
dr / dt: rate of change of the position of an object with respect to time
Therefore, we know that in a position graph with respect to time, both variables are proportional.
The proportionality constant is the speed of the object.
Mathematically, this constant represents the slope of the line.
Answer:
To calculate the velocity of an object, the slope of the position vs. time graph should be calculated.