You might want to look at the help file for -adjust-. Here are some examples:
sysuse auto
qreg price weight length foreign
adjust
adjust, by(foreign)
adjust, by(rep78)
adjust, by(rep78 foreign)
adjust weight length, by(foreign)
Best,
Alan
On Wed, Jan 14, 2009 at 1:30 PM, I M <[email protected]> wrote:
> Hello,
>
> I have a multivariate model (quantile regression, qreg) with a set of covariates.
>
> I have run the quantile regression model, then generated predicted values (values adjusted according to the covariates in my model).
>
> Essentially, these predicted values are the predicted medians.
>
> How do I summarize these predicted medians? i.e. if I want to report the predicted median by gender, how would I do this?
>
>
>
> ---begin example---
> /*quantile regression model*/
> qreg [outcome] [predictor variable 1] [predictor variable 2, i.e. gender]
>
> /*generate predicted medians based on estimates*/
> predict [predicted medians], xb
>
> /*summarize the predicted values*/
> sum [predicted medians], detail
>
> ---end example---
>
>
>
> The sum, detail command would give me the percentiles and the mean (and some other statistics).
>
> If I want to summarize the predicted medians, would I state the mean from the "sum" command, or would I state the median from the "sum" command?
>
> In other words, do I want to report the mean of the 'predicted median', or the median of the 'predicted median'?
>
> Thank you immensely!
>
> *
> * For searches and help try:
> * http://www.stata.com/help.cgi?search
> * http://www.stata.com/support/statalist/faq
> * http://www.ats.ucla.edu/stat/stata/
>
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/