Hello,
As the title suggests, I've created a lovely KM curve adjusted for by an interaction term of 2 covariates, but I'm unable to add a risk table to the generated graph, or perform a subsequent log-rank test.
For the unadjusted KM with a risk table, I use:
and the following for the log rank:
The adjusted KM curve is generated with the following:
However, when I input the following code:
I am returned with this error:
And
returns
Any help would be appreciated! I've been searching around with no luck, so it may be possible that these functions are not doable at all, however if there are ways around these errors then I'd be really grateful to hear!
As the title suggests, I've created a lovely KM curve adjusted for by an interaction term of 2 covariates, but I'm unable to add a risk table to the generated graph, or perform a subsequent log-rank test.
For the unadjusted KM with a risk table, I use:
Code:
sts graph, by(Calcification) risktable
Code:
sts test Calcification, logrank
Code:
sts graph, strata(Calcification) adjustfor(lengthgrade#calcgrade)
Code:
sts graph, strata(Calcification) adjustfor(lengthgrade#calcgrade) risktable
options adjustfor() and risktable may not be combined r(198)
Code:
sts test Calcification adjustfor(lengthgrade#calcgrade), logrank
factor-variable and time-series operators not allowed r(101)
Comment