Hello Statalist Community,
I am performing a landmark survival analysis to investigate whether the addition of chemotherapy to surgery for older patients (age>=80) with pancreatic cancer is associated with improved overall survival. My dependent variable, overall survival, was calculated as time from 90 days after diagnosis until death or last known follow-up, I used this landmark time point of 90 days from diagnosis until death or last know follow-up and excluded patients who died within 90 days of diagnosis to account for immortal time bias. My exposure was receipt of chemotherapy after surgery.
I have two variables that define follow up time (months):
Graph A:

Graph B:

I am performing a landmark survival analysis to investigate whether the addition of chemotherapy to surgery for older patients (age>=80) with pancreatic cancer is associated with improved overall survival. My dependent variable, overall survival, was calculated as time from 90 days after diagnosis until death or last known follow-up, I used this landmark time point of 90 days from diagnosis until death or last know follow-up and excluded patients who died within 90 days of diagnosis to account for immortal time bias. My exposure was receipt of chemotherapy after surgery.
I have two variables that define follow up time (months):
- Real follow-up time (t=postopfu) *
- landmarked time (postopfu90=t-3 mo)
Code:
** Follow up time** summarize postopfu, detail generate postopfu90 = postopfu - 3 summarize postopfu90, detail ** A: Overall survival - landmark time accounted for ** stset postopfu90, failure(laststatus==1) stci by anychemo: stci, median sts test anychemo, logrank stset postopfu90, failure(laststatus==1) sts graph, by(anychemo) tmin(3) tmax(60) xtitle(Time (months)) xlabel(0 12 24 36 48 60) risktable(, size(3) order(1 "No Chemotherapy" 2 "Chemotherapy")) legend(label(1 "No Chemotherapy") label (2 "Chemotherapy") title(, size(1))) title("") xline(3, lcolor(blue) lpattern(dash)) ** B: Overall survival - real follow up time ** stset postopfu, failure(laststatus==1) enter(time 3) origin(time 3) stci by anychemo: stci, median sts test anychemo, logrank sts graph, by(anychemo) tmin(3) tmax(60) xtitle(Time (months)) xlabel(0 12 24 36 48 60) risktable(, size(3) order(1 "No Chemotherapy" 2 "Chemotherapy")) legend(label(1 "No Chemotherapy") label (2 "Chemotherapy") title(, size(1))) title("") xline(3, lcolor(blue) lpattern(dash))
Graph B:
Comment