View source: R/within_cycle_corrections.R
gen_wcc | R Documentation |
gen_wcc
generates a vector of within-cycle corrections (WCC).
gen_wcc(n_cycles, method = c("Simpson1/3", "half-cycle", "none"))
n_cycles |
number of cycles |
method |
The method to be used for within-cycle correction. |
The default method is an implementation of Simpson's 1/3rd rule that generates a vector with the first and last entry with 1/3 and the odd and even entries with 4/3 and 2/3, respectively.
Method "half-cycle
" is the half-cycle correction method that
generates a vector with the first and last entry with 1/2 and the rest equal
to 1.
Method "none
" does not implement any within-cycle correction and
generates a vector with ones.
A vector of length n_cycles + 1
with within-cycle corrections
Elbasha EH, Chhatwal J. Myths and misconceptions of within-cycle correction: a guide for modelers and decision makers. Pharmacoeconomics. 2016;34(1):13-22.
Elbasha EH, Chhatwal J. Theoretical foundations and practical applications of within-cycle correction methods. Med Decis Mak. 2016;36(1):115-131.
# Number of cycles
n_cycles <- 10
gen_wcc(n_cycles = n_cycles, method = "Simpson1/3")
gen_wcc(n_cycles = n_cycles, method = "half-cycle")
gen_wcc(n_cycles = n_cycles, method = "none")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.