I have a graph which points are:

(-1,-2),(0,2),(1,4)

would the equation for this line be

y=3x+1

No. These points do not lie on a line. If you read the points off of a graph, you read them wrong.