| Title: | Regional Consistency Probability for Single-Arm Multi-Regional Clinical Trials |
|---|---|
| Description: | Provides functions to calculate and visualise the Regional Consistency Probability (RCP) for single-arm multi-regional clinical trials (MRCTs) using the Effect Retention Approach (ERA). Six endpoint types are supported: continuous, binary, count (negative binomial), time-to-event via hazard ratio, milestone survival, and restricted mean survival time (RMST). For each endpoint, both a closed-form (or semi-analytical) solution and a Monte Carlo simulation approach are implemented. Two consistency evaluation methods are available: Method 1 (effect retention in Region 1 relative to the overall population) and Method 2 (simultaneous positive effect across all regions). Plotting functions generate faceted visualisations of RCP as a function of the regional allocation proportion, overlaying formula and simulation results for direct comparison. The methodology follows the Japanese MHLW guidelines for MRCTs. Abbreviations used: RCP (Regional Consistency Probability), MRCT (Multi-Regional Clinical Trial), RMST (Restricted Mean Survival Time), MHLW (Ministry of Health, Labour and Welfare). |
| Authors: | Gosuke Homma [aut, cre] |
| Maintainer: | Gosuke Homma <[email protected]> |
| License: | MIT + file LICENSE |
| Version: | 0.1.1 |
| Built: | 2026-05-08 09:20:50 UTC |
| Source: | https://github.com/gosukehommaex/singlearmmrct |
Generate a faceted plot of Regional Consistency Probability (RCP) as a function
of the regional allocation proportion for binary endpoints.
Formula and simulation results are shown together for both Method 1 and Method 2.
Facet columns correspond to total sample sizes specified in N_vec.
Regional sample sizes are allocated as:
and
.
plot_rcp1armBinary( p = 0.5, p0 = 0.2, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )plot_rcp1armBinary( p = 0.5, p0 = 0.2, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )
p |
Numeric scalar. True response rate under the alternative hypothesis.
Must be in |
p0 |
Numeric scalar. Null hypothesis response rate. Must be in |
PI |
Numeric scalar. Effect retention threshold for Method 1.
Must be in |
N_vec |
Integer vector. Total sample sizes for each facet column.
Default is |
J |
Positive integer (>= 2). Number of regions. Default is |
f1_seq |
Numeric vector. Sequence of Region 1 allocation proportions.
Each value must be in |
nsim |
Positive integer. Number of Monte Carlo iterations for simulation.
Default is |
seed |
Non-negative integer. Random seed for simulation. Default is |
base_size |
Positive numeric. Base font size in points passed to
|
A ggplot2 object.
p <- plot_rcp1armBinary( p = 0.5, p0 = 0.2, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)p <- plot_rcp1armBinary( p = 0.5, p0 = 0.2, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)
Generate a faceted plot of Regional Consistency Probability (RCP) as a function
of the regional allocation proportion for continuous endpoints.
Formula and simulation results are shown together for both Method 1 and Method 2.
Facet columns correspond to total sample sizes specified in N_vec.
Regional sample sizes are allocated as:
and
.
plot_rcp1armContinuous( mu = 0.5, mu0 = 0.1, sd = 1, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )plot_rcp1armContinuous( mu = 0.5, mu0 = 0.1, sd = 1, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )
mu |
Numeric scalar. True mean under the alternative hypothesis.
Default is |
mu0 |
Numeric scalar. Null hypothesis mean. Default is |
sd |
Numeric scalar. True standard deviation. Must be positive.
Default is |
PI |
Numeric scalar. Effect retention threshold for Method 1.
Must be in |
N_vec |
Integer vector. Total sample sizes for each facet column.
Default is |
J |
Positive integer (>= 2). Number of regions. Default is |
f1_seq |
Numeric vector. Sequence of Region 1 allocation proportions.
Each value must be in |
nsim |
Positive integer. Number of Monte Carlo iterations for simulation.
Default is |
seed |
Non-negative integer. Random seed for simulation. Default is |
base_size |
Positive numeric. Base font size in points passed to
|
A ggplot2 object.
p <- plot_rcp1armContinuous( mu = 0.5, mu0 = 0.1, sd = 1, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)p <- plot_rcp1armContinuous( mu = 0.5, mu0 = 0.1, sd = 1, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)
Generate a faceted plot of Regional Consistency Probability (RCP) as a function
of the regional allocation proportion for count endpoints
(negative binomial model).
Formula and simulation results are shown for Method 1 (log-RR and linear-RR
scales) and Method 2. Facet rows correspond to the two Method 1 scales
( and ), and facet columns correspond to total
sample sizes specified in N_vec.
Regional sample sizes are allocated as:
and
.
plot_rcp1armCount( lambda = 2, lambda0 = 3, dispersion = 1, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )plot_rcp1armCount( lambda = 2, lambda0 = 3, dispersion = 1, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )
lambda |
Numeric scalar. Expected count per patient under the alternative
hypothesis. Must be positive. Default is |
lambda0 |
Numeric scalar. Expected count per patient under the historical
control. Must be positive. Default is |
dispersion |
Numeric scalar. Dispersion parameter of the negative binomial
distribution. Must be positive. Default is |
PI |
Numeric scalar. Effect retention threshold for Method 1.
Must be in |
N_vec |
Integer vector. Total sample sizes for each facet column.
Default is |
J |
Positive integer (>= 2). Number of regions. Default is |
f1_seq |
Numeric vector. Sequence of Region 1 allocation proportions.
Each value must be in |
nsim |
Positive integer. Number of Monte Carlo iterations for simulation.
Default is |
seed |
Non-negative integer. Random seed for simulation. Default is |
base_size |
Positive numeric. Base font size in points passed to
|
A ggplot2 object.
p <- plot_rcp1armCount( lambda = 2, lambda0 = 3, dispersion = 1, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)p <- plot_rcp1armCount( lambda = 2, lambda0 = 3, dispersion = 1, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)
Generate a faceted plot of Regional Consistency Probability (RCP) as a function
of the regional allocation proportion for hazard ratio endpoints.
Formula and simulation results are shown for Method 1 (log-HR and linear-HR
scales) and Method 2. Facet rows correspond to the two Method 1 scales
( and ), and facet columns correspond to total
sample sizes specified in N_vec.
Regional sample sizes are allocated as:
and
.
plot_rcp1armHazardRatio( lambda = log(2)/10, lambda0 = log(2)/5, t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )plot_rcp1armHazardRatio( lambda = log(2)/10, lambda0 = log(2)/5, t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )
lambda |
Numeric scalar. True hazard rate under the alternative hypothesis.
Must be positive. Default is |
lambda0 |
Numeric scalar. Historical control hazard rate. Must be positive.
Default is |
t_a |
Numeric scalar. Accrual period. Must be positive. Default is |
t_f |
Numeric scalar. Follow-up period. Must be positive. Default is |
lambda_dropout |
Numeric scalar or |
PI |
Numeric scalar. Effect retention threshold for Method 1.
Must be in |
N_vec |
Integer vector. Total sample sizes for each facet column.
Default is |
J |
Positive integer (>= 2). Number of regions. Default is |
f1_seq |
Numeric vector. Sequence of Region 1 allocation proportions.
Each value must be in |
nsim |
Positive integer. Number of Monte Carlo iterations for simulation.
Default is |
seed |
Non-negative integer. Random seed for simulation. Default is |
base_size |
Positive numeric. Base font size in points passed to
|
A ggplot2 object.
p <- plot_rcp1armHazardRatio( lambda = log(2) / 10, lambda0 = log(2) / 5, t_a = 3, t_f = 10, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)p <- plot_rcp1armHazardRatio( lambda = log(2) / 10, lambda0 = log(2) / 5, t_a = 3, t_f = 10, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)
Generate a faceted plot of Regional Consistency Probability (RCP) as a function
of the regional allocation proportion for milestone survival endpoints.
Formula and simulation results are shown together for both Method 1 and Method 2.
Facet columns correspond to total sample sizes specified in N_vec.
Regional sample sizes are allocated as:
and
.
plot_rcp1armMilestoneSurvival( lambda = log(2)/10, t_eval = 8, S0 = exp(-log(2) * 8/5), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )plot_rcp1armMilestoneSurvival( lambda = log(2)/10, t_eval = 8, S0 = exp(-log(2) * 8/5), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )
lambda |
Numeric scalar. True hazard rate under the alternative hypothesis.
Must be positive. Default is |
t_eval |
Numeric scalar. Milestone evaluation time point. Must be positive.
Default is |
S0 |
Numeric scalar. Historical control survival rate at |
t_a |
Numeric scalar. Accrual period. Must be positive. Default is |
t_f |
Numeric scalar. Follow-up period. Must be positive. Default is |
lambda_dropout |
Numeric scalar or |
PI |
Numeric scalar. Effect retention threshold for Method 1.
Must be in |
N_vec |
Integer vector. Total sample sizes for each facet column.
Default is |
J |
Positive integer (>= 2). Number of regions. Default is |
f1_seq |
Numeric vector. Sequence of Region 1 allocation proportions.
Each value must be in |
nsim |
Positive integer. Number of Monte Carlo iterations for simulation.
Default is |
seed |
Non-negative integer. Random seed for simulation. Default is |
base_size |
Positive numeric. Base font size in points passed to
|
A ggplot2 object.
p <- plot_rcp1armMilestoneSurvival( lambda = log(2) / 10, t_eval = 8, S0 = exp(-log(2) * 8 / 5), t_a = 3, t_f = 10, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)p <- plot_rcp1armMilestoneSurvival( lambda = log(2) / 10, t_eval = 8, S0 = exp(-log(2) * 8 / 5), t_a = 3, t_f = 10, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)
Generate a faceted plot of Regional Consistency Probability (RCP) as a function
of the regional allocation proportion for restricted mean survival
time (RMST) endpoints.
Formula and simulation results are shown together for both Method 1 and Method 2.
Facet columns correspond to total sample sizes specified in N_vec.
Regional sample sizes are allocated as:
and
.
plot_rcp1armRMST( lambda = log(2)/10, tau_star = 8, mu0 = (1 - exp(-log(2)/5 * 8))/(log(2)/5), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )plot_rcp1armRMST( lambda = log(2)/10, tau_star = 8, mu0 = (1 - exp(-log(2)/5 * 8))/(log(2)/5), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, N_vec = c(20, 40, 100), J = 3, f1_seq = seq(0.1, 0.9, by = 0.1), nsim = 10000, seed = 1, base_size = 28 )
lambda |
Numeric scalar. True hazard rate under the alternative hypothesis.
Must be positive. Default is |
tau_star |
Numeric scalar. Truncation time for RMST calculation. Must be
positive and no greater than the total study duration |
mu0 |
Numeric scalar. Historical control RMST at |
t_a |
Numeric scalar. Accrual period. Must be positive. Default is |
t_f |
Numeric scalar. Follow-up period. Must be positive. Default is |
lambda_dropout |
Numeric scalar or |
PI |
Numeric scalar. Effect retention threshold for Method 1.
Must be in |
N_vec |
Integer vector. Total sample sizes for each facet column.
Default is |
J |
Positive integer (>= 2). Number of regions. Default is |
f1_seq |
Numeric vector. Sequence of Region 1 allocation proportions.
Each value must be in |
nsim |
Positive integer. Number of Monte Carlo iterations for simulation.
Default is |
seed |
Non-negative integer. Random seed for simulation. Default is |
base_size |
Positive numeric. Base font size in points passed to
|
A ggplot2 object.
lam0 <- log(2) / 5 tstar <- 8 mu0_val <- (1 - exp(-lam0 * tstar)) / lam0 p <- plot_rcp1armRMST( lambda = log(2) / 10, tau_star = tstar, mu0 = mu0_val, t_a = 3, t_f = 10, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)lam0 <- log(2) / 5 tstar <- 8 mu0_val <- (1 - exp(-lam0 * tstar)) / lam0 p <- plot_rcp1armRMST( lambda = log(2) / 10, tau_star = tstar, mu0 = mu0_val, t_a = 3, t_f = 10, PI = 0.5, N_vec = c(20, 40, 100), J = 3 ) print(p)
Print Method for rcp1armBinary Objects
## S3 method for class 'rcp1armBinary' print(x, ...)## S3 method for class 'rcp1armBinary' print(x, ...)
x |
An object of class |
... |
Additional arguments (not used). |
Invisibly returns the input object x.
Print Method for rcp1armContinuous Objects
## S3 method for class 'rcp1armContinuous' print(x, ...)## S3 method for class 'rcp1armContinuous' print(x, ...)
x |
An object of class |
... |
Additional arguments (not used). |
Invisibly returns the input object x.
Print Method for rcp1armCount Objects
## S3 method for class 'rcp1armCount' print(x, ...)## S3 method for class 'rcp1armCount' print(x, ...)
x |
An object of class |
... |
Additional arguments (not used). |
Invisibly returns the input object x.
Print Method for rcp1armHazardRatio Objects
## S3 method for class 'rcp1armHazardRatio' print(x, ...)## S3 method for class 'rcp1armHazardRatio' print(x, ...)
x |
An object of class |
... |
Additional arguments (not used). |
Invisibly returns the input object x.
Print Method for rcp1armMilestoneSurvival Objects
## S3 method for class 'rcp1armMilestoneSurvival' print(x, ...)## S3 method for class 'rcp1armMilestoneSurvival' print(x, ...)
x |
An object of class |
... |
Additional arguments (not used). |
Invisibly returns the input object x.
Print Method for rcp1armRMST Objects
## S3 method for class 'rcp1armRMST' print(x, ...)## S3 method for class 'rcp1armRMST' print(x, ...)
x |
An object of class |
... |
Additional arguments (not used). |
Invisibly returns the input object x.
Calculate the regional consistency probability (RCP) for binary endpoints in single-arm multi-regional clinical trials (MRCTs) using the Effect Retention Approach (ERA).
Two evaluation methods are supported:
Method 1: Effect retention approach. Evaluates whether Region 1 retains
at least a fraction PI of the overall treatment effect:
.
Method 2: Simultaneous positivity across all regions.
Evaluates whether all regional response rates exceed the null value:
.
Two calculation approaches are available:
"formula": Exact closed-form solution via full enumeration of
the binomial joint distribution. Method 1 uses a two-block decomposition
(Region 1 vs regions 2..J combined), which is valid for .
Method 2 supports regions.
"simulation": Monte Carlo simulation. Supports regions.
rcp1armBinary( p, p0, Nj, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )rcp1armBinary( p, p0, Nj, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )
p |
Numeric scalar. True response rate under the alternative hypothesis.
Must be in |
p0 |
Numeric scalar. Null hypothesis response rate (baseline or historical
control). Must be in |
Nj |
Integer vector. Sample sizes for each region. For example,
|
PI |
Numeric scalar. Prespecified effect retention threshold for Method 1.
Typically |
approach |
Character scalar. Calculation approach: |
nsim |
Positive integer. Number of Monte Carlo iterations. Used only when
|
seed |
Non-negative integer. Random seed for reproducibility. Used only
when |
An object of class "rcp1armBinary", which is a list containing:
approachCalculation approach used ("formula" or
"simulation").
nsimNumber of Monte Carlo iterations (NULL for
"formula" approach).
pTrue response rate under the alternative hypothesis.
p0Null hypothesis response rate.
NjSample sizes for each region.
PIEffect retention threshold.
Method1RCP using Method 1 (effect retention).
Method2RCP using Method 2 (all regions positive).
# Example 1: Exact solution with N = 100, Region 1 has 10 subjects result1 <- rcp1armBinary( p = 0.5, p0 = 0.2, Nj = c(10, 90), PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100, Region 1 has 10 subjects result2 <- rcp1armBinary( p = 0.5, p0 = 0.2, Nj = c(10, 90), PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)# Example 1: Exact solution with N = 100, Region 1 has 10 subjects result1 <- rcp1armBinary( p = 0.5, p0 = 0.2, Nj = c(10, 90), PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100, Region 1 has 10 subjects result2 <- rcp1armBinary( p = 0.5, p0 = 0.2, Nj = c(10, 90), PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)
Calculate the regional consistency probability (RCP) for continuous endpoints in single-arm multi-regional clinical trials (MRCTs) using the Effect Retention Approach (ERA).
Two evaluation methods are supported:
Method 1: Effect retention approach. Evaluates whether Region 1 retains
at least a fraction PI of the overall treatment effect:
.
Method 2: Simultaneous positivity across all regions.
Evaluates whether all regional estimates exceed the null value:
.
Two calculation approaches are available:
"formula": Closed-form analytical solution based on normal
approximation. Method 1 uses a two-block decomposition (Region 1 vs
regions 2..J combined), which is valid for .
Method 2 supports regions.
"simulation": Monte Carlo simulation. Supports regions.
rcp1armContinuous( mu, mu0, sd, Nj, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )rcp1armContinuous( mu, mu0, sd, Nj, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )
mu |
Numeric scalar. True mean under the alternative hypothesis. |
mu0 |
Numeric scalar. Null hypothesis mean (baseline or historical control).
The treatment effect is defined as |
sd |
Numeric scalar. True standard deviation, assumed common across all regions. Must be positive. |
Nj |
Integer vector. Sample sizes for each region. For example,
|
PI |
Numeric scalar. Prespecified effect retention threshold for Method 1.
Typically |
approach |
Character scalar. Calculation approach: |
nsim |
Positive integer. Number of Monte Carlo iterations. Used only when
|
seed |
Non-negative integer. Random seed for reproducibility. Used only
when |
An object of class "rcp1armContinuous", which is a list containing:
approachCalculation approach used ("formula" or
"simulation").
nsimNumber of Monte Carlo iterations (NULL for
"formula" approach).
muTrue mean under the alternative hypothesis.
mu0Null hypothesis mean.
sdStandard deviation.
NjSample sizes for each region.
PIEffect retention threshold.
Method1RCP using Method 1 (effect retention).
Method2RCP using Method 2 (all regions positive).
# Example 1: Closed-form solution with N = 100, Region 1 has 10 subjects result1 <- rcp1armContinuous( mu = 0.5, mu0 = 0.1, sd = 1, Nj = c(10, 90), PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100, Region 1 has 10 subjects result2 <- rcp1armContinuous( mu = 0.5, mu0 = 0.1, sd = 1, Nj = c(10, 90), PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)# Example 1: Closed-form solution with N = 100, Region 1 has 10 subjects result1 <- rcp1armContinuous( mu = 0.5, mu0 = 0.1, sd = 1, Nj = c(10, 90), PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100, Region 1 has 10 subjects result2 <- rcp1armContinuous( mu = 0.5, mu0 = 0.1, sd = 1, Nj = c(10, 90), PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)
Calculate the regional consistency probability (RCP) for count (overdispersed) endpoints in single-arm multi-regional clinical trials (MRCTs) using the Effect Retention Approach (ERA).
Count data are modelled by the negative binomial distribution, and the treatment
effect is expressed as a rate ratio (RR) relative to a historical control rate
. Two effect scales are considered:
Log-RR scale: .
Linear-RR scale: .
Two evaluation methods are supported (for each scale):
Method 1: Effect retention approach. Evaluates whether Region 1 retains
at least a fraction PI of the overall treatment effect.
Log-RR: ;
Linear-RR: .
Method 2: Simultaneous benefit across all regions.
Evaluates whether all regional rate ratios are below 1:
for all .
(Equivalent for both log-RR and linear-RR scales.)
Two calculation approaches are available:
"formula": Exact closed-form solution via full enumeration of
the negative binomial joint distribution. Method 1 uses a two-block
decomposition (Region 1 vs regions 2..J combined), which is valid for
. Method 2 supports regions.
"simulation": Monte Carlo simulation. Supports regions.
rcp1armCount( lambda, lambda0, dispersion, Nj, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )rcp1armCount( lambda, lambda0, dispersion, Nj, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )
lambda |
Numeric scalar. Expected count per patient under the alternative hypothesis. Must be positive. |
lambda0 |
Numeric scalar. Expected count per patient under the historical control (null hypothesis reference value). Must be positive. |
dispersion |
Numeric scalar. Dispersion parameter (size) of the negative binomial distribution, assumed common across all regions. Smaller values indicate greater overdispersion. Must be positive. |
Nj |
Integer vector. Sample sizes for each region. For example,
|
PI |
Numeric scalar. Prespecified effect retention threshold for Method 1.
Typically |
approach |
Character scalar. Calculation approach: |
nsim |
Positive integer. Number of Monte Carlo iterations. Used only when
|
seed |
Non-negative integer. Random seed for reproducibility. Used only
when |
An object of class "rcp1armCount", which is a list containing:
approachCalculation approach used ("formula" or
"simulation").
nsimNumber of Monte Carlo iterations (NULL for
"formula" approach).
lambdaExpected count per patient under the alternative hypothesis.
lambda0Expected count per patient under the historical control.
dispersionDispersion parameter.
NjSample sizes for each region.
PIEffect retention threshold.
Method1_logRRRCP using Method 1 (log-RR scale).
Method1_linearRRRCP using Method 1 (linear-RR scale).
Method2RCP using Method 2 (all regions show benefit; identical for log-RR and linear-RR scales).
# Example 1: Exact solution with N = 100, Region 1 has 10 subjects result1 <- rcp1armCount( lambda = 2, lambda0 = 3, dispersion = 1, Nj = c(10, 90), PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100, Region 1 has 10 subjects result2 <- rcp1armCount( lambda = 2, lambda0 = 3, dispersion = 1, Nj = c(10, 90), PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)# Example 1: Exact solution with N = 100, Region 1 has 10 subjects result1 <- rcp1armCount( lambda = 2, lambda0 = 3, dispersion = 1, Nj = c(10, 90), PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100, Region 1 has 10 subjects result2 <- rcp1armCount( lambda = 2, lambda0 = 3, dispersion = 1, Nj = c(10, 90), PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)
Calculate the regional consistency probability (RCP) for time-to-event endpoints using the hazard ratio (HR) in single-arm multi-regional clinical trials (MRCTs) using the Effect Retention Approach (ERA).
Event times are modelled by the exponential distribution with hazard rate
(treatment) relative to a known historical control hazard
. The treatment effect is expressed as a hazard ratio:
(benefit). Two effect scales are considered:
Log-HR scale: .
Linear-HR scale: .
Two evaluation methods are supported (for each scale):
Method 1: Effect retention approach. Evaluates whether Region 1 retains
at least a fraction PI of the overall treatment effect.
Log-HR: ;
Linear-HR: .
Method 2: Simultaneous benefit across all regions.
Evaluates whether all regional hazard ratios are below 1:
for all .
(Equivalent for both log-HR and linear-HR scales.)
Two calculation approaches are available:
"formula": Closed-form solution based on normal approximation for
and the delta method for the linear-HR scale
(Hayashi and Itoh 2018). Method 1 uses a two-block decomposition (Region 1
vs regions 2..J combined), which is valid for .
Method 2 supports regions.
"simulation": Monte Carlo simulation using individual patient data
with person-years estimation of the hazard rate. Supports regions.
rcp1armHazardRatio( lambda, lambda0, Nj, t_a, t_f, lambda_dropout = NULL, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )rcp1armHazardRatio( lambda, lambda0, Nj, t_a, t_f, lambda_dropout = NULL, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )
lambda |
Numeric scalar. True hazard rate under the alternative hypothesis.
Must be positive. Under exponential distribution, median survival =
|
lambda0 |
Numeric scalar. Known hazard rate for the historical control (null hypothesis reference value). Must be positive. |
Nj |
Integer vector. Sample sizes for each region. For example,
|
t_a |
Numeric scalar. Accrual period (patient enrolment duration). Must be positive. |
t_f |
Numeric scalar. Follow-up period (additional follow-up after accrual ends). Must be positive. |
lambda_dropout |
Numeric scalar or |
PI |
Numeric scalar. Prespecified effect retention threshold for Method 1.
Typically |
approach |
Character scalar. Calculation approach: |
nsim |
Positive integer. Number of Monte Carlo iterations. Used only when
|
seed |
Non-negative integer. Random seed for reproducibility. Used only
when |
An object of class "rcp1armHazardRatio", which is a list containing:
approachCalculation approach used ("formula" or
"simulation").
nsimNumber of Monte Carlo iterations (NULL for
"formula" approach).
lambdaTrue hazard rate under the alternative hypothesis.
lambda0Historical control hazard rate.
NjSample sizes for each region.
t_aAccrual period.
t_fFollow-up period.
tauTotal study duration ().
lambda_dropoutDropout hazard rate (NA if NULL).
PIEffect retention threshold.
Method1_logHRRCP using Method 1 (log-HR scale).
Method1_linearHRRCP using Method 1 (linear-HR scale).
Method2RCP using Method 2 (all regions show benefit; identical for log-HR and linear-HR scales).
Hayashi N, Itoh Y (2017). A re-examination of Japanese sample size calculation for multi-regional clinical trial evaluating survival endpoint. Japanese Journal of Biometrics, 38(2): 79–92.
Wu J (2015). Sample size calculation for the one-sample log-rank test. Pharmaceutical Statistics, 14(1): 26–33.
# Example 1: Closed-form solution with N = 100, Region 1 has 10 subjects result1 <- rcp1armHazardRatio( lambda = log(2) / 10, lambda0 = log(2) / 5, Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100, Region 1 has 10 subjects result2 <- rcp1armHazardRatio( lambda = log(2) / 10, lambda0 = log(2) / 5, Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)# Example 1: Closed-form solution with N = 100, Region 1 has 10 subjects result1 <- rcp1armHazardRatio( lambda = log(2) / 10, lambda0 = log(2) / 5, Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100, Region 1 has 10 subjects result2 <- rcp1armHazardRatio( lambda = log(2) / 10, lambda0 = log(2) / 5, Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)
Calculate the regional consistency probability (RCP) for milestone survival endpoints in single-arm multi-regional clinical trials (MRCTs) using the Effect Retention Approach (ERA).
Event times are modelled by the exponential distribution with hazard rate
(treatment). The treatment effect at a prespecified evaluation
time is expressed as the difference in survival rates:
, where
is the historical control survival rate at .
Two evaluation methods are supported:
Method 1: Effect retention approach. Evaluates whether Region 1 retains
at least a fraction PI of the overall treatment effect:
.
Method 2: Simultaneous benefit across all regions.
Evaluates whether all regional Kaplan-Meier estimates exceed the historical
control: .
Two calculation approaches are available:
"formula": Closed-form or semi-analytical solution based on the
asymptotic variance of the Kaplan-Meier estimator derived from Greenwood's
formula. When , the
administrative censoring survival function and the
variance integral has a closed-form solution. When
, the integral is evaluated numerically via
integrate. Method 1 uses a two-block decomposition
(Region 1 vs regions 2..J combined). Method 2 supports
regions.
"simulation": Monte Carlo simulation with vectorized Kaplan-Meier
estimation. Supports regions.
rcp1armMilestoneSurvival( lambda, t_eval, S0, Nj, t_a, t_f, lambda_dropout = NULL, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )rcp1armMilestoneSurvival( lambda, t_eval, S0, Nj, t_a, t_f, lambda_dropout = NULL, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )
lambda |
Numeric scalar. True hazard rate under the alternative hypothesis. Must be positive. |
t_eval |
Numeric scalar. Evaluation time point for the milestone survival probability. Must be positive. |
S0 |
Numeric scalar. Historical control survival rate at |
Nj |
Integer vector. Sample sizes for each region. For example,
|
t_a |
Numeric scalar. Accrual period (patient enrolment duration). Must be positive. |
t_f |
Numeric scalar. Follow-up period (additional follow-up after accrual ends). Must be positive. |
lambda_dropout |
Numeric scalar or |
PI |
Numeric scalar. Prespecified effect retention threshold for Method 1.
Typically |
approach |
Character scalar. Calculation approach: |
nsim |
Positive integer. Number of Monte Carlo iterations. Used only when
|
seed |
Non-negative integer. Random seed for reproducibility. Used only
when |
Variance formula.
The asymptotic variance of the Kaplan-Meier estimator for a
single arm with subjects is derived from Greenwood's formula:
where is the overall censoring
survival function, and
Under the exponential model , this simplifies to:
Closed-form solution ().
When , throughout
, and the integral reduces to:
Therefore:
When there is no dropout (), this further simplifies to the
binomial variance:
An object of class "rcp1armMilestoneSurvival", which is a list
containing:
approachCalculation approach used ("formula" or
"simulation").
formula_typeFor approach = "formula": either
"closed-form" (when ) or
"numerical-integration" (when ).
NULL for simulation.
nsimNumber of Monte Carlo iterations (NULL for
"formula" approach).
lambdaTrue hazard rate under the alternative hypothesis.
NjSample sizes for each region.
t_aAccrual period.
t_fFollow-up period.
tauTotal study duration ().
lambda_dropoutDropout hazard rate (NA if NULL).
PIEffect retention threshold.
eval_timeMilestone evaluation time point.
S0Historical control survival rate at eval_time.
S_estTrue survival rate under the alternative at
eval_time: .
Method1RCP using Method 1 (effect retention).
Method2RCP using Method 2 (all regions positive).
Wu J (2015). Sample size calculation for the one-sample log-rank test. Pharmaceutical Statistics, 14(1): 26–33.
# Example 1: Closed-form solution (t_eval <= t_f) with N = 100 result1 <- rcp1armMilestoneSurvival( lambda = log(2) / 10, t_eval = 8, S0 = exp(-log(2) * 8 / 5), Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100 result2 <- rcp1armMilestoneSurvival( lambda = log(2) / 10, t_eval = 8, S0 = exp(-log(2) * 8 / 5), Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)# Example 1: Closed-form solution (t_eval <= t_f) with N = 100 result1 <- rcp1armMilestoneSurvival( lambda = log(2) / 10, t_eval = 8, S0 = exp(-log(2) * 8 / 5), Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100 result2 <- rcp1armMilestoneSurvival( lambda = log(2) / 10, t_eval = 8, S0 = exp(-log(2) * 8 / 5), Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)
Calculate the regional consistency probability (RCP) for restricted mean survival time (RMST) endpoints in single-arm multi-regional clinical trials (MRCTs) using the Effect Retention Approach (ERA).
Event times are modelled by the exponential distribution with hazard rate
(treatment). The treatment effect is expressed as the difference
in RMST at a prespecified truncation time :
, where is
the historical control RMST at .
The regional RMST estimator is defined as the area under the Kaplan-Meier
curve up to :
.
Two evaluation methods are supported:
Method 1: Effect retention approach. Evaluates whether Region 1 retains
at least a fraction PI of the overall treatment effect:
.
Method 2: Simultaneous benefit across all regions.
Evaluates whether all regional RMST estimates exceed the historical
control RMST: .
Two calculation approaches are available:
"formula": Normal approximation based on exponential event times
and exponential dropout. When (the most common setting
in practice), the administrative censoring survival function equals 1 on
and the variance integral has a closed-form solution.
When , the integral is evaluated numerically via
integrate. Method 1 uses a two-block decomposition
(Region 1 vs regions 2..J combined), valid for .
Method 2 supports regions.
"simulation": Monte Carlo simulation. The RMST for each
simulation replicate is computed as the exact area under the Kaplan-Meier
step function (sum of rectangles). Supports regions.
rcp1armRMST( lambda, tau_star, mu0, Nj, t_a, t_f, lambda_dropout = NULL, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )rcp1armRMST( lambda, tau_star, mu0, Nj, t_a, t_f, lambda_dropout = NULL, PI = 0.5, approach = "formula", nsim = 10000, seed = 1 )
lambda |
Numeric scalar. True hazard rate under the alternative hypothesis. Must be positive. |
tau_star |
Numeric scalar. Truncation time for RMST calculation. Must be
positive and no greater than the total study duration |
mu0 |
Numeric scalar. Historical control RMST at |
Nj |
Integer vector. Sample sizes for each region. For example,
|
t_a |
Numeric scalar. Accrual period (patient enrolment duration). Must be positive. |
t_f |
Numeric scalar. Follow-up period (additional follow-up after accrual ends). Must be positive. |
lambda_dropout |
Numeric scalar or |
PI |
Numeric scalar. Prespecified effect retention threshold for Method 1.
Typically |
approach |
Character scalar. Calculation approach: |
nsim |
Positive integer. Number of Monte Carlo iterations. Used only when
|
seed |
Non-negative integer. Random seed for reproducibility. Used only
when |
Variance formula.
The asymptotic variance of the RMST estimator for a
single arm with subjects is:
where is the overall censoring
survival function:
Closed-form variance ().
When , on and the
integrand reduces to
.
Expanding and integrating term by term:
where for and
.
When there is no dropout () this further reduces to:
An object of class "rcp1armRMST", which is a list containing:
approachCalculation approach used ("formula" or
"simulation").
formula_typeFor approach = "formula": either
"closed-form" (when ) or
"numerical-integration" (when ).
NULL for simulation.
nsimNumber of Monte Carlo iterations (NULL for
"formula" approach).
lambdaTrue hazard rate under the alternative hypothesis.
NjSample sizes for each region.
t_aAccrual period.
t_fFollow-up period.
tauTotal study duration ().
lambda_dropoutDropout hazard rate (NA if NULL).
PIEffect retention threshold.
tau_starTruncation time for RMST.
mu0Historical control RMST at tau_star.
mu_estTrue RMST under the alternative:
.
Method1RCP using Method 1 (effect retention).
Method2RCP using Method 2 (all regions positive).
Wu J (2015). Sample size calculation for the one-sample log-rank test. Pharmaceutical Statistics, 14(1): 26–33.
# Example 1: Closed-form solution (tau_star <= t_f) with N = 100 lam <- log(2) / 10 lam0 <- log(2) / 5 tstar <- 8 mu0_val <- (1 - exp(-lam0 * tstar)) / lam0 result1 <- rcp1armRMST( lambda = lam, tau_star = tstar, mu0 = mu0_val, Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100 result2 <- rcp1armRMST( lambda = lam, tau_star = tstar, mu0 = mu0_val, Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)# Example 1: Closed-form solution (tau_star <= t_f) with N = 100 lam <- log(2) / 10 lam0 <- log(2) / 5 tstar <- 8 mu0_val <- (1 - exp(-lam0 * tstar)) / lam0 result1 <- rcp1armRMST( lambda = lam, tau_star = tstar, mu0 = mu0_val, Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "formula" ) print(result1) # Example 2: Monte Carlo simulation with N = 100 result2 <- rcp1armRMST( lambda = lam, tau_star = tstar, mu0 = mu0_val, Nj = c(10, 90), t_a = 3, t_f = 10, lambda_dropout = NULL, PI = 0.5, approach = "simulation", nsim = 10000, seed = 1 ) print(result2)