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

From |
"Martin Weiss" <martin.weiss1@gmx.de> |

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

Subject |
st: RE: reg ..., noc if... ? |

Date |
Thu, 13 Aug 2009 21:03:23 +0200 |

<> -If- qualifiers go before the comma, they are not part of the options, but a category in its own right... HTH Martin -----Original Message----- From: owner-statalist@hsphsun2.harvard.edu [mailto:owner-statalist@hsphsun2.harvard.edu] On Behalf Of Stata Chris Sent: Donnerstag, 13. August 2009 21:00 To: statalist@hsphsun2.harvard.edu Subject: st: reg ..., noc if... ? Dear Statalisters, I am using the following loop: gen beta = . gen se_beta = . gen t_beta = . forvalues i=456/515{ capture noisily { reg delta L.delta if period==`i' replace beta = _b[L.delta] if period==`i' replace se_beta = _se[L.delta] if period==`i' replace t_beta = beta / se_beta if period==`i' } } Now I wanted to impose the constraint on each of the regressions that the constant should equal zero. However, if I add ",noc" (no constant), then Stata interprets everything after the comma as an option and tells me that "if period..." is not a valid option. So I was wondering if there is any way to have both the noc constraint and the if condition here? Many thanks, Chris * * 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/

**References**:**st: reg ..., noc if... ?***From:*Stata Chris <statachris@gmail.com>

- Prev by Date:
**st: reg ..., noc if... ?** - Next by Date:
**Re: st: RE: reg ..., noc if... ?** - Previous by thread:
**st: reg ..., noc if... ?** - Next by thread:
**Re: st: RE: reg ..., noc if... ?** - Index(es):

© Copyright 1996–2016 StataCorp LP | Terms of use | Privacy | Contact us | What's new | Site index |