The hardware and bandwidth for this mirror is donated by METANET, the Webhosting and Full Service-Cloud Provider.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]metanet.ch.
trtswitch provides methods for treatment switching
adjustment in randomized clinical trials, including:
Install from GitHub:
# install.packages("remotes")
remotes::install_github("kaifenglu/trtswitch")library(trtswitch)
library(dplyr)
# Build treatment exposure proportion used by rpsftm
# in the one-way switching example dataset.
data <- immdef %>%
mutate(rx = 1 - xoyrs / progyrs)
fit <- rpsftm(
data = data,
id = "id",
time = "progyrs",
event = "prog",
treat = "imm",
rx = "rx",
censor_time = "censyrs",
boot = FALSE
)
fit
# Key estimates
fit$psi
fit$hr
fit$psi_CI
fit$hr_CIThese binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.