The rate of change is (-1)
To solve this, we need to look at graphic to know the values of the function f(x) when x is equal to 1 and 3.
Then we have two points of the graph: (1,6) and (3,4).
The rate of change between two points is:

In this case,

Note that its the same whatever coordinate put first:

But when you do the difference between the coordinates, make sure to respect the order: if you use the y coordinate of the point P minus the y coordinate of point Q, you must to do the same for the x coodinate; Px-Qx