Statalist


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

Re: st: Statistical test for trends


From   Matt Spittal <Matt.Spittal@cancervic.org.au>
To   <statalist@hsphsun2.harvard.edu>
Subject   Re: st: Statistical test for trends
Date   Tue, 21 Apr 2009 12:29:05 +1000

Ashwin,

There's a couple of different ways to include a trend term in your model.
You can have a variable that ranges from 1 to 4 (or 0 to 3) and enter this
directly into your model.  This tests the hypothesis that there is a linear
relationship between time and your outcome.  This is a fairly straight
forward approach and usually works quite well.

Your findings, however, suggest that there might be a non-linear
relationship between time and the outcome. If so you could also enter a
variable into the model that is time^2 to attempt to account for this.
Sometimes this approach can work well, other times it is a poor
approximation of the underlying process and alternatives such as splines
work better.

But with only 4 time points, my suggestion would be to dummy-code time and
enter the three parameters into the model.  Use a Wald test or
log-likelihood ratio test to see if the parameters are jointly associated
with the outcome. If it is, then you can interpret the individual time
parameters in relation to the (omitted) reference category.

Finally, there's always a lot to gain from plotting the outcome variable
against time.  This will quickly give you a sense of whether the
relationship is linear or not, and whether there is any underlying trend.

-- Matt
matt.spittal@cancervic.org.au

  




On 21/4/09 11:50 AM, "Ashwin Ananthakrishnan" <ashwinna@yahoo.com> wrote:

> Hello, 
> 
> I was wondering if someone could suggest the best statistical test for trends
> in Stata. 
> 
> I'm analyzing proportion of patients on certain medications over 4 consecutive
> time periods. I'm also analyzing the rates of hospitalization over the same
> time period (continuous variable, since 1 patient can have more than 1
> hospitalization).
> 
> For example, 
> 
>           % on med       rate of hospitalization (/100 pts)
> Year 1      21                5
> Year 2      25                4
> Year 3      29                8
> Year 4      33                3
> 
> 
> Even say a test for trend doesn't meet statistical significance for the % on
> the medication, the % on med in year 1 may be statistically different from
> Year 4 (and similarly for the rate of hospitalization between Year 3 and Year
> 4, but not overall trend for Years 1 - 4). How does one interpret these
> findings? 
> 
> Is correlation analysis the best way to test the significance of the trend?
> 
> Thanks, 
> 
> Ashwin
>                  
> 
> 
> 
> 
>       
> *
> *   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/



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