Hi Listers,
I am interested in assessing the relationship between diabetes diagnosis (yes/no) and age in my data. In the summary statistics, we report results by age group but for this analysis I am opting to use age as continuous - still to clear it with my colleagues.
it was suggested I may want to use the Cochran-Armitage trend test using ptrend
ptrend nyes nno age
The Chi2 for departure has p<.001 which suggests the null hypothesis is not met. Does it mean that I should not be using the CA test as the assumption of linearity is not met?
I am also considering that, seen that I am using age as continuous, I could simply run a simple logistic regression with age as a predictor. Is there a way to assess if there is a linear association between diagnosis and age? Plotting the data shows a decrease with a dip at age 55 which is followed by an increase in diagnosis rates which suggests a non-linear association.
What's the best way forward?
Thank you in advance!
Related Posts with Trend analysis - ptrend
numeric format & changed valueI am using ver.15 and created ID from PIDM (to convert ID to string). The PIDM column is %10.0g. How…
Testing whether difference between interacted coefficients is not larger than thresholdDear all, this is probably quite a simple issue for people that are familiar with the test command …
Adding percentages to bars in an histogramDear Statalisters I want to create an histogram representing the percentages corresponding to each …
Controlling for fixed effectsHi guys I have another thread active, but i think my explanation was not clear, why i am trying aga…
unit root test for panel dataHI , I am trying to do unit root test for panel data I have tried dfuller test, but stata bring erro…
Subscribe to:
Post Comments (Atom)
0 Response to Trend analysis - ptrend
Post a Comment