Perhaps something like this:
clear
sysuse auto
estsimp regress price mpg fore, sims(100000)
setx mpg 12 fore 1
simqi, ev genev(expected_price)
histogram expected, norm
This uses programs from Michael Tomz, Jason Wittenberg, and Gary King's
clarify.
Scott
> -----Original Message-----
> From: [email protected] [mailto:owner-
> [email protected]] On Behalf Of Randall
> Sent: Monday, April 17, 2006 9:16 AM
> To: [email protected]
> Subject: Re: st: Bell Curve of Predicted Values
>
> Maarten, thanks. This seems very close to what I
> would like to do. I had been calculating my predicted
> values using matrix language, just because I had
> particular x-values I was interested in obtaining a
> prediction for. Using your example, I did something
> like this:
>
> reg price mpg foreign
> matrix yhat=_b[_cons] + _b[mpg]*12 + _b[foreign]*1
> matrix list yhat
>
> So in essence, I wanted a prediction for mpg=12,
> foreign=1.
>
> So my question is this: is there a way of generating
> a distribution based on particular criteria (i.e.
> mpg=12, foreign=1)?
>
> Thanks again,
> Randall
>
*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/