[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

From |
Roger Newson <roger.newson@kcl.ac.uk> |

To |
statalist@hsphsun2.harvard.edu |

Subject |
st: RE: statsby? |

Date |
Tue, 03 May 2005 18:19:11 +0100 |

An alternative possibility is to use -parmest- together with -somersd- to produce an output dataset (or resultsset) with 1 observation per Kendall's tau-a, which you can then list and/or plot and/or tabulate. This method has the advantage of producing confidence limits as well as P-values for Kendall's tau-a, and also the option of using a normalising and/or variance stabilising transformation, such as the arcsine or the hyperbolic arctangent. The -somersd- and -parmest- packages are both downloadable from SSC.

To find out more about confidence intervals for Kendall's tau-a and other rank statistics, type in Stata

findit params

and you will be signposted to my website, where you can download a preprint of Newson (2002). To find out more about -parmest- and resultssets in general, type

findit resultsset

and you will be signposted to my website, where you can download a copy of my Stata User Meeting presentation on resultssets.

I hope this helps.

Roger

References

Newson R. 2002. Parameters behind "nonparametric" statistics: Kendall's tau, Somers' D and median differences. The Stata Journal 2(1): 45-64.

At 16:43 03/05/2005, you wrote:

Dear Nick Your solution is exactly what I needed. A thousend thanks, Sascha Nick Winter wrote:In Stata 8, this should do the trick: . statsby "ktau x y " TauB=r(tau_b) P=r(p) , by(z) saving(myfile) In Stata 9, it would be: statsby TauB=r(tau_b) P=r(p) , by(z) saving(myfile) : ktau x y --Nick Winter At 04:49 PM 5/3/2005 +0200, you wrote:With STATA 8, I tried

_statsby "ktau x y" exp_list, by(v w z) saving(myfile)_

where for exp_list I tried _se and _b (I have to admit that the grammar of exp_list remains a riddle to me).

The error produced is r(301): last estimates not found.

Regards, Sascha

Nick Cox wrote:

In principle, -statsby- sounds a good solution.

However, we cannot comment on what went wrong without seeing your code. Also, the syntax of -statsby- differs between Stata 8 and Stata 9, so you would need to specify version as well.

Nick n.j.cox@durham.ac.uk

Sascha Robert

I have to do a bunch of Kendall's tau correlations. Now the output of

_ktau x y, by(z)_

is quite exaustive, and I am mostly interested in

- Kendall's tau-a

- Prob > ¦z¦

Is there a way to direclty produce a table of the results, like

tau-a prob ...

a b ...

c d ...,

instead of producing text output?

Is _statsby_ a solution for my problem? It does not seem to work for my puposes, though.

* * For searches and help try: * http://www.stata.com/support/faqs/res/findit.html * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/-- ***** sascha robert | mailto: sascha.robert@iew.unizh.ch ***** * * For searches and help try: * http://www.stata.com/support/faqs/res/findit.html * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/-------------------------------------------------------- Nicholas Winter 607.255.8819 t Assistant Professor 607.255.4530 f Department of Government nw53@cornell.edu e 308 White Hall falcon.arts.cornell.edu/nw53 w Cornell University Ithaca, NY 14853-4601 * * For searches and help try: * http://www.stata.com/support/faqs/res/findit.html * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/-- ***** sascha robert | mailto: sascha.robert@iew.unizh.ch ***** * * For searches and help try: * http://www.stata.com/support/faqs/res/findit.html * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/

-- Roger Newson Lecturer in Medical Statistics Department of Public Health Sciences Division of Asthma, Allergy and Lung Biology King's College London 5th Floor, Capital House 42 Weston Street London SE1 3QD United Kingdom 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 Email: roger.newson@kcl.ac.uk Website: http://phs.kcl.ac.uk/rogernewson/ Opinions expressed are those of the author, not the institution. * * For searches and help try: * http://www.stata.com/support/faqs/res/findit.html * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/

**References**:**st: RE: statsby?***From:*"Nick Cox" <n.j.cox@durham.ac.uk>

**Re: st: RE: statsby?***From:*Nick Winter <nw53@cornell.edu>

**Re: st: RE: statsby?***From:*Sascha Robert <sascha.robert@iew.unizh.ch>

- Prev by Date:
**RE: st: Question about producing fit statistics after logistic with pweights** - Next by Date:
**st: treatment effects - two step** - Previous by thread:
**Re: st: RE: statsby?** - Next by thread:
**st: Kaplan-Meier** - Index(es):

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