Skip to content

Commit 5fc24f3

Browse files
author
NightlordTW
committed
Update vignette
1 parent 9b05fe1 commit 5fc24f3

File tree

2 files changed

+43
-11
lines changed

2 files changed

+43
-11
lines changed

R/helper.r

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,12 @@ print.simss <- function(x, ...) {
2121
output <- data.frame(Parameter = c("Total Sample Size", "Achieved Power", "Power Confidence Interval"),
2222
Value = c(sst, 100*power, paste0(100*lpower, " - ", 100*upower)))
2323

24-
message(cat("Sample Size Calculation Results"))
25-
message(cat("-------------------------------------------------------------"))
26-
message(cat(paste0("Study Design: ", x$param.d$dtype, " trial targeting ",100*tpower,"% power with a ",100*alpha, "% type-I error.")))
27-
24+
message("Sample Size Calculation Results")
25+
cat("-------------------------------------------------------------\n")
26+
cat(paste0("Study Design: ", x$param.d$dtype, " trial targeting ",100*tpower,"% power with a ",100*alpha, "% type-I error.\n"))
27+
cat("-------------------------------------------------------------\n")
2828
print(output, row.names = FALSE) # Suppress row numbers
29+
#cat("-------------------------------------------------------------\n")
2930
#print(x$response[,-1], row.names = FALSE)
3031
}
3132

vignettes/sampleSize_parallel_2A3E.Rmd

Lines changed: 38 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -64,12 +64,12 @@ For both endpoints, the analysis assumes that:
6464

6565
To evaluate bioequivalence, we apply the $80\%/125\%$ rule, which defines equivalence bounds relative to the reference mean. The evaluation is conducted using a one-sided significance level of 5\%, with a target statistical power of 90\%.
6666

67-
# Testing the Difference of Means (DOM) for multiple Co-primary Endpoints
68-
In biosimilar development, it is important to demonstrate equivalence across all relevant doses, routes of administration, patient populations, and endpoints. To establish equivalence between two treatments, the difference in means for each endpoint, $\mu_{T}^{(j)} - \mu_{R}^{(j)}$, must lie within a predefined equivalence margin around zero for all primary endpoints.
6967

7068
## Hypotheses
7169
The null and alternative hypotheses for the equivalence test are as follows:
7270

71+
### Difference of Means (DOM)
72+
7373
Null Hypothesis ($H_0$): At least one endpoint does not meet the equivalence criteria:
7474

7575
$$H_0: \mu_T^{(j)} - \mu_R^{(j)} \le E_L ~~ \text{or}~~ \mu_T^{(j)} - \mu_R^{(j)} \ge E_U \quad \text{for at least one}\;j$$
@@ -78,14 +78,39 @@ Alternative Hypothesis ($H_1$): All endpoints meet the equivalence criteria:
7878

7979
$$H_1: E_L<\mu_{T}^{(j)}-\mu_{R}^{(j)} < E_U \quad\text{for all}\;j$$
8080

81-
The null hypothesis ($H_0$) is rejected if, and only if, all null hypotheses associated with the $K$ primary endpoints are rejected at a significance level of $\alpha$. This ensures that equivalence is established across all endpoints simultaneously.
81+
The null hypothesis ($H_0$) is rejected if, and only if, all null hypotheses associated with the $K$ primary endpoints are rejected at a significance level of $\alpha$. This ensures that equivalence is established across all endpoints simultaneously.
82+
83+
### Ratio of Means (ROM)
84+
The equivalence hypotheses can also be expressed as a Ratio of Means (ROM), which is often used in bioequivalence studies:
85+
86+
Null Hypothesis ($H_0$): At least one endpoint does not meet the equivalence criteria:
87+
88+
$$H_0: \frac{\mu_T^{(j)}}{\mu_R^{(j)}} \le \log(E_L) ~~ \text{or}~~ \frac{\mu_T^{(j)}}{\mu_R^{(j)}} \ge \log(E_U) \quad \text{for at least one}\;j$$
89+
90+
Alternative Hypothesis ($H_1$): All endpoints meet the equivalence criteria:
91+
92+
$$H_1: \log(E_L)< \frac{\mu_{T}^{(j)}}{\mu_{R}^{(j)}} < \log(E_U) \quad\text{for all}\;j$$
93+
8294

8395
## Statistical Considerations
8496

85-
* **Type I Error Control**: Since rejection of $H_0$ requires all individual null hypotheses to be rejected, there is no need for multiplicity adjustments. The Type I error rate is controlled by the design.
86-
* **Impact on Power**: Requiring equivalence across multiple endpoints decreases the overall power of the test. The Type II error increases as the number of primary endpoints ($K$) grows, which can make equivalence testing more challenging [@mielke_sample_2018].
97+
### Consistency Across Endpoints
98+
For equivalence to be established, all primary endpoints must simultaneously satisfy the equivalence criteria. This applies whether the criteria are expressed as:
8799

88-
## Independent Testing of Pharmacokinetic (PK) Measures
100+
* The Difference of Means (DOM) approach measures absolute differences between treatment means.
101+
* The Ratio of Means (ROM) approach captures relative differences and is commonly used when analyzing log-transformed data, such as in pharmacokinetic studies.
102+
103+
### Type I Error Control
104+
Rejection of the null hypothesis ($H_0$) requires that all individual null hypotheses across endpoints be rejected. Since the test is designed to achieve equivalence simultaneously for all endpoints, there is no need for multiplicity adjustments, and the Type I error rate is controlled by the study design.
105+
106+
### Impact on Power
107+
Requiring equivalence across multiple endpoints reduces the overall power of the test. Specifically:
108+
109+
* The Type II error increases as the number of primary endpoints ($K$) grows.
110+
* This makes equivalence testing more challenging for studies with multiple endpoints, as additional endpoints require larger sample sizes or stronger effect sizes to achieve sufficient power [@mielke_sample_2018].
111+
112+
113+
## Independent Testing of PK Measures
89114
If each pharmacokinetic (PK) measure is tested independently, the following sample sizes would be required for each endpoint to achieve a 5\% significance level:
90115

91116
```{r}
@@ -135,8 +160,14 @@ library(SimTOST)
135160
))
136161
```
137162

163+
If we were to test each PK measure independently, we would find a total sample size of `r sim_AUCinf$response$n_total` for AUCinf, `r sim_AUClast$response$n_total` for AUClast, and `r sim_Cmax$response$n_total` for Cmax. This means that we would have to enroll `r sim_AUCinf$response$n_total` + `r sim_AUClast$response$n_total` + `r sim_Cmax$response$n_total` = `r sim_AUCinf$response$n_total + sim_AUClast$response$n_total + sim_Cmax$response$n_total` patients in order to reject $H_0$ at a significance level of 5\%. For context, the original trial was a randomized, single-blind, three-arm, parallel-group study conducted in 159 healthy subjects, slightly more than the `r sim_AUCinf$response$n_total + sim_AUClast$response$n_total + sim_Cmax$response$n_total` patients estimated as necessary. This suggests that the original trial had a small buffer above the calculated sample size requirements.
164+
165+
## Simultaneous Testing of PK Measures with Independent Endpoints
166+
This approach focuses on simultaneous testing of pharmacokinetic (PK) measures while assuming independence between endpoints. Unlike the previous approach, which evaluated each PK measure independently, this method integrates comparisons across multiple endpoints, accounting for correlations (or lack thereof) between them. By doing so, it enables simultaneous testing for equivalence without inflating the overall Type I error rate.
167+
168+
In this setting, equivalence is required for at least one endpoint rather than all endpoints, reducing the overall sample size compared to independent testing. Furthermore, this approach allows for greater flexibility by enabling users to specify correlation structures or work with uncorrelated endpoints as a default assumption.
169+
138170

139-
If we were to test each PK measure independently, we would find a total sample size of `r sim_AUCinf$response$n_total` for AUCinf, `r sim_AUClast$response$n_total` for AUClast, and `r sim_Cmax$response$n_total` for Cmax. This means that we would have to enroll `r sim_AUCinf$response$n_total` + `r sim_AUClast$response$n_total` + `r sim_Cmax$response$n_total` = `r sim_AUCinf$response$n_total + sim_AUClast$response$n_total + sim_Cmax$response$n_total`$ patients in order to reject $H_0$ at a significance level of 5\%.
140171

141172

142173

0 commit comments

Comments
 (0)