Package: npsurvSS 1.1.0

npsurvSS: Sample Size and Power Calculation for Common Non-Parametric Tests in Survival Analysis

A number of statistical tests have been proposed to compare two survival curves, including the difference in (or ratio of) t-year survival, difference in (or ratio of) p-th percentile survival, difference in (or ratio of) restricted mean survival time, and the weighted log-rank test. Despite the multitude of options, the convention in survival studies is to assume proportional hazards and to use the unweighted log-rank test for design and analysis. This package provides sample size and power calculation for all of the above statistical tests with allowance for flexible accrual, censoring, and survival (eg. Weibull, piecewise-exponential, mixture cure). It is the companion R package to the paper by Yung and Liu (2020) <doi:10.1111/biom.13196>. Specific to the weighted log-rank test, users may specify which approximations they wish to use to estimate the large-sample mean and variance. The default option has been shown to provide substantial improvement over the conventional sample size and power equations based on Schoenfeld (1981) <doi:10.1093/biomet/68.1.316>.

Authors:Godwin Yung [aut, cre], Yi Liu [aut]

npsurvSS_1.1.0.tar.gz
npsurvSS_1.1.0.zip(r-4.7-any)npsurvSS_1.1.0.zip(r-4.6-any)npsurvSS_1.1.0.zip(r-4.5-any)
npsurvSS_1.1.0.tgz(r-4.6-any)npsurvSS_1.1.0.tgz(r-4.5-any)
npsurvSS_1.1.0.tar.gz(r-4.7-any)npsurvSS_1.1.0.tar.gz(r-4.6-any)
npsurvSS_1.1.0.tgz(r-4.6-emscripten)
manual.pdf |manual.html✨
DESCRIPTION
card.svg |card.png
npsurvSS/json (API)

# Install 'npsurvSS' in R:
install.packages('npsurvSS', repos = c('https://godwinyyung.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/godwinyung/npsurvss/issues

On CRAN:

Conda:

4.10 score 1 stars 1 packages 14 scripts 658 downloads 30 exports 0 dependencies

Last updated from:f86e7e8590. Checks:9 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-develOK114
source / vignettesOK229
linux-releaseOK103
macos-releaseOK134
macos-oldrelOK171
windows-develOK68
windows-releaseOK63
windows-oldrelOK51
wasm-releaseOK78

Exports:create_armcreate_arm_lachindaccrdlossdmaxUdminimaxUdsurvemaxUeminimaxUexp_durationexp_eventshlosshsurvpaccrper2hazplosspmaxUpminimaxUpower_two_armpsurvqaccrqlossqminimaxUqsurvraccrrlossrsurvsimulate_armsimulate_trialsize_two_arm

Dependencies:

Example 1: Optimal randomization ratio
Preliminaries | Figure 1C | Figure 2

Last update: 2024-03-29
Started: 2019-08-16

Example 2: Delayed treatment effect
Figure 3 | Figure 4A

Last update: 2024-03-29
Started: 2019-08-16

Basic functionalities
Creating objects of class "arm" | Visualizing distributional assumptions | Calculating power and sample size | Event-driven trials | Simulating a trial

Last update: 2019-08-16
Started: 2019-08-16

Readme and manuals

Help Manual

Help pageTopics
Create an 'arm' objectcreate_arm
Create a 'lachin' objectcreate_arm_lachin
Accrualdaccr paccr qaccr raccr
Loss to follow-updloss hloss ploss qloss rloss
Maximum observed timedmaxU emaxU pmaxU
Minimax observed timedminimaxU eminimaxU pminimaxU qminimaxU
Survivaldsurv hsurv psurv qsurv rsurv
Expected durationexp_duration
Expected number of eventsexp_events
Convert exponential parametersper2haz
Powerpower_two_arm
Simulate complete data for a single armsimulate_arm
Simulate a clinical trialsimulate_trial
Sample sizesize_two_arm