View source: R/TwoSample.Q.Cov.Estimator.Sequential.LR.R
| TwoSample.Q.Cov.Estimator.Sequential.LR | R Documentation |
Computes the stage-wise generalized log-rank statistics and their variance estimates at a set of interim analysis
calendar times. At each analysis, administrative censoring is applied at the specified calendar time, event times are converted from the
calendar-time scale to the event-time scale (time since enrollment), and the generalized log-rank statistics is
evaluated over [0, tau]. When multiple analysis are requested, the function also estimates the correlation
matrix of the stage-wise statistics.
TwoSample.Q.Cov.Estimator.Sequential.LR(data, tau = 3, calendars)
data |
A data.frame generated by |
tau |
Positive numeric value specifying the upper bound of event time
(time since enrollment) for integration of the statistic. Default is
|
calendars |
Numeric vector of interim analysis calendar times (in years) at which to compute stage-wise statistics and variance estimates. |
A list containing stage-wise estimates. If length(calendars) > 1,
the returned list includes:
Qs: Numeric vector of stage-wise generalized log-rank statistics
evaluated at each calendar time in calendars.
vars: Numeric vector of estimated variances corresponding to
Qs.
total.ns: Numeric vector giving the total enrolled sample size
contributing data at each calendar time.
corr.matrix: Estimated correlation matrix of the stage-wise
statistics.
nss: List of length length(calendars) giving the
group-specific sample sizes at each analysis.
If length(calendars) == 1, the list contains Qs, vars,
and total.ns.
df <- TwoSample.generate.sequential(sizevec = c(200, 200), beta.trt = 0,
calendar = 5, recruitment = 3, random.censor.rate = 0.05, seed = 2026)
TwoSample.Q.Cov.Estimator.Sequential.LR(data = df, calendars = c(2.5, 3.5, 4.5))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.