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

From |
"Tiago V. Pereira" <tiago.pereira@incor.usp.br> |

To |
statalist@hsphsun2.harvard.edu |

Subject |
st: How to know how a global macro was generated: -smr- as an example |

Date |
Thu, 11 Dec 2008 17:34:58 -0200 (BRST) |

Dear all, Not rarely I almost drive myself crazy because several Stata commands fail to provide info about the formulations they use to compute variances/standard errors in their calculations. I have already claimed that most Stata packages should provide references on their formulae/and or to point out where we can get detailed info on the methods implemented. When no reference is given, I usually open the code and see how it was calculated, trying to find ou in textbooks similar formulations. However, in the case of the -smrby- command, which calculates the ratio of OBSERVED/EXPECTED counts and its confidence intervals, I could not figure out how the global macros S_1 and S_2 were computed. Once you can rapidly take a look on the code of the -smr- command, I did not paste the whole code here for simplicity. Specifically, I am interested in the following lines: if _rc==0 { _crccip `o' `level' local l=100*($S_1/`e') local u=100*($S_2/`e') local r=100*(`o'/`e') local emark "" } I will be really grateful for any tip on how both $S_1 and $S_2 were calculated. All the best, Tiago Pereira * * 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/

**Follow-Ups**:**st: RE: How to know how a global macro was generated: -smr- as an example***From:*"Nick Cox" <n.j.cox@durham.ac.uk>

**st: Re: How to know how a global macro was generated: -smr- as an example***From:*"Martin Weiss" <martin.weiss1@gmx.de>

- Prev by Date:
**st: RE: RE: Pearson correlate returned values: corr vs. pwcorr** - Next by Date:
**st: Re: How to know how a global macro was generated: -smr- as an example** - Previous by thread:
**st: copy values** - Next by thread:
**st: Re: How to know how a global macro was generated: -smr- as an example** - Index(es):

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