Enter the following input to create a command that will plot a collection of data, a fit function, and the residuals for the data and the given function. Test the command with the fit function f(x)= 3-.25x+.125x^2
residualPlot[data_,function_,{x_,xmin_,xmax_},opts___Rule]:=
Show[ListPlot[{data,Table[{x,function}, {x,data[[All,1]]}]}, Filling -> {1->{2}},
FillingStyle-> {Red,Green}, PlotMarkers-> {"*",""}, opts],
Plot[function, {x,xmin,xmax}]]