Description Usage Arguments Value References See Also Examples
View source: R/Sample_Size_for_EV.R
Precise estimate of calibration slope
1 | ss_cal_slope(R2, lambda, width, alpha)
|
R2 |
Expected coefficient of determination (R2) of the calibration model |
lambda |
Anticipated (mis)calibration across the range of predicted values |
width |
Width of confidence interval of lambda |
alpha |
Level of Significance |
A html file contains minimum sample size
Archer L, Snell KIE, Ensor J, Hudda MT, Collins GS, Riley RD. Minimum sample size for external validation of a clinical prediction model with a continuous outcome. Stat Med. 2020;40:133-46.
ss_citl, ss_R2val , ss_res_var , ss_sens , ss_spec
1 2 3 4 5 6 7 8 | #Eg. Sample size to target a 95% confidence interval for 𝜆cal
#that has a narrow width ≤ 0.2 (eg, if the calibration slope was 1,
# the confidence interval would be 0.9 to 1.1 assuming confidence
#intervals derived by 𝜆̂cal ± 1.96SE𝜆̂cal) and assuming R2val = 0.5 .
ss_cal_slope( R2= 0.5,width = 0.2,alpha = 0.05, lambda = 1)
#for different combinations of parameters
ss_cal_slope( R2= c(0.7,0.8),width =c( 1.1,1.2),alpha = 0.05, lambda = 1)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.