{smcl}
{* 3nov2004}{...}
{hline}
help for {hi:ovfplot}{right:(SJ4-4: gr0009)}
{hline}

{title:Plots of observed versus fitted values after model fit}

{p 8 17 2}{cmd:ovfplot}
[{cmd:,} 
{it:scatter_options}
{cmd:plot(}{it:plot}{cmd:)} 
]   


{title:Description}

{p 4 4 2}{cmd:ovfplot} plots observed versus fitted or predicted values for the
response from an immediately previous {cmd:regress} or similar command, with 
a line of equality superimposed. 


{title:Options}

{p 4 8 2} 
{it:scatter_options} affect the rendition of the plotted points; see
{help scatter}.
Note also that the presentation of the line of equality observed = fitted  
can be tuned by using the options {cmd:clstyle()}, 
{cmd:clpattern()}, {cmd:clwidth()}, and {cmd:clcolor()}. 

{p 4 8 2}{cmd:plot(}{it:plot}{cmd:)} provides a way to add other plots to the
generated graph; see {help plot_option}. 


{title:Remarks} 

{p 4 4 2}In more technical detail, {cmd:ovfplot} plots a single dependent or
response variable as specified in {cmd:e(depvar)} on the y-axis and
whatever single variable is calculated by the default of {cmd:predict} on the
x-axis, which makes sense whenever those variables are on the same scale.
 
{p 4 4 2}The plot is restricted to the estimation sample.  


{title:Examples}

{p 4 8 2}{cmd:. sysuse auto}

{p 4 8 2}{cmd:. regress mpg weight}{p_end}
{p 4 8 2}{cmd:. ovfplot}{p_end}
{p 4 8 2}{cmd:. gen weightsq = weight^2}{p_end}
{p 4 8 2}{cmd:. regress mpg weight weightsq}{p_end}
{p 4 8 2}{cmd:. ovfplot}

{p 4 8 2}{cmd:. glm mpg weight foreign, link(log)}{p_end}
{p 4 8 2}{cmd:. ovfplot, by(foreign)}


{title:Author}

{p 4 4 2}Nicholas J. Cox, University of Durham, U.K.{break} 
n.j.cox@durham.ac.uk
    

{title:Also see}

{p 4 13 2}Online:  help for {help predict}, {help scatter}, {help modeldiag} 
{p_end}
