Notice: On March 31, it was **announced** that Statalist is moving from an email list to a **forum**. The old list will shut down on April 23, and its replacement, **statalist.org** is already up and running.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

From |
"Nakelse, Tebila (AfricaRice)" <T.Nakelse@cgiar.org> |

To |
"statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu> |

Subject |
st: Margin with two step estimator. |

Date |
Thu, 2 Feb 2012 08:18:59 +0000 |

Dear Stata Users, I've estimated a two-step equations. The first step is a logit and the second one is E(Y| p,X)= a + bp + cx +... where p is the predicted probability of the first step. I want to use the margin command to have the predicted value of E(Y| p,X). But my problem is to tell to margin that I want him to predict p and after to predict E(Y| p,X) simultaneously. What I have tried to do is to stack the b and V matrix of the two steps and give it to margins as his b and V matrix and write the full equation to be calculated by margin using the b elements as coefficients. But the main problem is to access the coefficients of the b or the V matrix of stata. Please is someone can help me ? Tebila * * 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/

- Prev by Date:
**st: RE: Use of data originating from SPSS** - Next by Date:
**st: Coding assistance.** - Previous by thread:
**st: Fixed lag smoothing in state space model** - Next by thread:
**st: Coding assistance.** - Index(es):