{smcl} {hline} help for {hi:stcomply}{right:(SJ4-3: st0068)} {hline} {title:Calculating Loeys and Goetghebeur estimate of compliance-adjusted treatment effect in survival data} {p 8 17 2} {cmd:stcomply} {it:group} {it:comply} [{cmd:if} {it:exp}] [{cmd:in} {it:range}] [{cmd:,} {cmd:data} {cmd:graph}[{cmd:(}{it:graph_options}{cmd:)}] {cmd:grfit}[{cmd:(}{it:graph_options}{cmd:)}] {cmdab:l:evel(}{it:#}{cmd:)} {cmdab:conv:crit(}{it:#}{cmd:)} ] {p 4 4 2} {cmd:stcomply} is for use with survival-time data. You must {cmd:stset} your data before using this command; see help {help stset}. {p 4 4 2} {it:group} contains the name of the variable holding the intervention assignment; {it:comply} contains the name of the variable holding the compliance data. {p 4 4 2} Both {it:group} and {it:comply} must contain binary data (two-arm trials, all-or-nothing compliance only). Compliance data must only apply to one arm of the trial (that with the higher value of {it:group}), and be set to missing for the other arm. {title:Description} {p 4 4 2} {cmd:stcomply} calculates the Loeys and Goetghebeur (2003) estimate and confidence interval of compliance-adjusted treatment effect in survival data, for all-or-nothing compliance in the treatment arm only. {title:Options} {p 4 8 2} {cmd:data} stores the values of adjusted hazard ratios searched over and the corresponding standard deviations from the observed hazard ratio, in matrix psi_z. {p 4 8 2} {cmd:graph} provides a graph of the standardised test statistic G0*(psi)/s(psi) against the hazard ratio psi, where G0*(psi) is the difference in the number of deaths resulting from the predicted survival function for the control arm and the number of deaths actually observed in the control arm. Where this function does not intersect the upper/lower horizontal lines, a confidence interval for psi cannot be calculated. Alternatively, {cmd:graph()} may be issued with options specifying details for the graph. {p 4 8 2} {cmd:grfit} provides Kaplan-Meier plots of predicted (based on potential compliers and non-compliers) and observed survival in the control arm. Alternatively, {cmd:grfit()} may be issued with options specifying details for the graph. {p 4 8 2}{it:graph_options} are options of {help twoway_line:twoway line}. {p 4 8 2} {cmd:level(}{it:#}{cmd:)} specifies the confidence level, in percent, for the confidence intervals of the Loeys and Goetghebeur estimate; see help {help level}. The default is the current value of $S_level. {p 4 8 2} {cmd:convcrit(}{it:#}{cmd:)} specifies the accuracy of convergence of z to the chosen confidence level. Default is within 0.01. {title:Remarks} {p 4 4 2} For detailed information on this estimation of compliance-adjusted treatment effect, see Loeys & Goetghebeur (2003). {title:Examples} {p 4 8 2}{cmd:. stcomply group comply}{p_end} {p 4 8 2}{cmd:. stcomply group comply, graph data level(90)}{p_end} {p 4 8 2}{cmd:. stcomply group comply, graph(saving(comply1)) grfit(saving(comply2)) data level(90)} {title:Authors} {p 4 4 2} L Kim, I White, MRC Biostatistics Unit, Cambridge, UK. {title:Reference} {p 4 8 2} Loeys, T. and E. Goetghebeur. 2003. A causal proportional hazards estimator for the effect of treatment actually received in a randomized trial with all-or-nothing compliance. {it:Biometrics} 59: 100-105.