[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: cubic spline
Hi
I am writing you to ask you kindly help me in some issues.
I want to run a spline cubic to assess the spline models with 95% CI
reflecting mortality predictability of dietary phosphorus in a group.
I have two variables:
1-Death
2- Phosphorus intake
Would you please help me which syntax I should use? I want the Y axis to
show the Log hazard ratio and the X axis to show the dietary phosphorus.
Also I want to know if I want to adjust for age make second spline) what
should I do. So far I ran these syntaxes:
stset time to death, failure(death)
stcox Phosphorus intake
predict hr1, hr
generate lnhr = ln(hr1)
I really appreciate in advance
Best regard
Nazanin Noori MD Ph.D
Harbor UCLA Medical Center
*
* 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/