[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
Re: st: Saved Results by Group
At 16:25 06/08/02 -0400, Dan Pregibon wrote:
No, there isn't. You need to use the -statsby- command of official Stata to
store the results of an analysis for multiple by-groups in a data set with
1 observation per by-group. See -help statsby- online or -[R] statsby- in
Suppose I am summarizing survival data with the command "stsum, by(group)"
and would like to store particular results of each group in a new variable
I have generated. The stored result "r(p50)", for example, will give me
the 50th percentile of the total set. Is there a stored result for the
50th percentile of just group 1 or group 2?
If you are doing analyses with by-groups using estimation commands such as
-stcox-, rather than r-class commands such as -sumby-, you can use either
-statsby- (to generate a data set with 1 observation per by-group) or
-parmby- (to generate a data set with 1 observation per parameter per
by-group and data on confidence limits, P-values and other things).
-parmby- is part of the -parmest- package, which you can download from SSC.
Type -ssc describe parmest- in Web-aware Stata to find out more.
I hope this helps.
Lecturer in Medical Statistics
Department of Public Health Sciences
King's College London
5th Floor, Capital House
42 Weston Street
London SE1 3QD
Tel: 020 7848 6648 International +44 20 7848 6648
Fax: 020 7848 6620 International +44 20 7848 6620
or 020 7848 6605 International +44 20 7848 6605
Opinions expressed are those of the author, not the institution.
* For searches and help try: