### Excerpt

Several factors affect the statistical power/detectable alternative of trend-in-trend studies, although we know of no closed-form solution to their estimation. We therefore developed a Monte Carlo simulation approach for estimating statistical power or detectable alternative when planning a trend-in-trend study. This approach requires the investigator to specify six parameters: (1) the type-1 error rate; (2) the probability of a study subject experiencing the study outcome during any study interval; (3) the c statistic of the cumulative probability of exposure model5; (4) the number of cumulative probability of exposure strata into which the population is divided; (5) the shape of the exposure trend, expressed as a linear or quadratic function of time on log scale; and (6) the desired statistical power or minimum detectable causal odds ratio. The simulation procedure (which has been incorporated into the TrendInTrend package for the R: https://cran.r-project.org/web/packages/TrendInTrend/index.html) provides an estimate for either the statistical power or the minimum detectable odds ratio, whichever was specified in (6) above. The eAppendix (http://links.lww.com/EDE/B308) provides technical information about the simulation procedure.

To illustrate the simulations and assess the influence of the required parameters, we estimated the statistical power of a hypothetical trend-in-trend study under different scenarios. We assumed (1) a type-1 error rate of 5%; (2) a proportion of the population experiencing the outcome during any study interval of 0.007, 0.018, and 0.049; (3) a c statistic for the cumulative probability of exposure model of 0.50, 0.60, and 0.75; (4) a number of strata of 5 and 10; (5) a linear time trend in exposure prevalence with slopes (αt) 0.07 and 0.20 relative percent over the study period (Figure A). We assumed that the study period was divided into 10 time intervals, and generated 500 datasets of size 10,000 (1,000 of whom were ever-exposed) for each scenario.

The Figure B–D displays simulated statistical power over odds ratios ranging from 1 to 2, with the dashed and the dotted lines representing weak

JOURNAL/epide/04.02/00001648-201805000-00021/math_21MM1/v/2018-04-21T053452Z/r/image-tiff

and strong

JOURNAL/epide/04.02/00001648-201805000-00021/math_21MM2/v/2018-04-21T053452Z/r/image-tiff

time trends in exposure, respectively. The Figure B shows the effect of the c statistic of the cumulative probability of exposure model and strength of exposure trend on power when the outcome rate over the entire study period is set to 0.015 and the number of cumulative probability strata is set to 5. The strength of exposure trend has a bigger influence on power than does the c statistic, although c statistic does have an observable effect. The Figure C shows the influence of the outcome probability when the c statistic is set at 0.75 and the number of cumulative probability of exposure strata is set to 5. As the outcome probability increases, power increases dramatically. The Figure D assesses the influence of number of cumulative probability of exposure strata, setting the c statistic to 0.75 and outcome probability to 0.015.