PseudoInv[x_]:=Inverse[Transpose[x].x].Transpose[x];

S={{0,0},{-1,1},{1,4},{2,3},{-2,2}};

PlotS=ListPlot[S,PlotMarkers->{"+", Medium},Axes->True,AxesOrigin->{-1,-1}]

(A=Table[{((S[[i,1]])^3),S[[i,1]],1},{i,1,5}])//MatrixForm

(B=Drop[S,{},{1}])//MatrixForm

Y=Flatten[N[PseudoInv[A].B]]

JimmyPlot=Plot[Y[[1]] (t^3)+Y[[2]] t+Y[[3]],{t,-4,4},PlotStyle->Red];

Show[PlotS,JimmyPlot,AxesOrigin->{0,0},PlotRange->All]

A.Y

B

A.Y-B

Norm[A.Y-B]