Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: nptrend question


From   Ricardo Ovaldia <ovaldia@yahoo.com>
To   statalist@hsphsun2.harvard.edu
Subject   st: nptrend question
Date   Tue, 18 Nov 2003 10:04:00 -0800 (PST)

Dear Stata users,

I used -nptrend- to perform a nonparametric test for
trend across ordered groups. I assumed that because it
was non-parametric the way that the groups were coded
was not important. I coded a severity of illness
variable as follows:

0 not severe
1 mildly severe
2 severe
3 most severe

I run the -nptrend- an obtained:

. nptr died, by(severe)

    severe     score       obs      sum of ranks
         0         0       129         19828
         1         1        88         13737
         2         2        66         11148
         3         3        39          7290

     z  =  2.75,  chi-squared(1) =   7.57
  P>|z| = 0.0059


When I recoded the severity variable as:

 0 not severe
.5 mildly severe
.7 severe
 1 most severe

but maintaining the order, to my surprise I obtained:

. nptr died, by(severe)

    severe     score       obs      sum of ranks
         0         0       129         19828
        .5        .5        88         13737
        .7        .7        66         11148
         1         1        39          7290

     z  =  2.52,  chi-squared(1) =   6.35
  P>|z| = 0.0117


I though that this nonparametric test would be
invariant to the scale and only affected by the
relative ordering of the categories. 

Is there a test for trend that is not affected by the
magnitude of the class variable values?

Ricardo.

=====
Ricardo Ovaldia, MS
Statistician 
Oklahoma City, OK

__________________________________
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree
*
*   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/



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