Skip to contents

This function can estimate Kendall's \(\tau\) as follows: Oakes (1982)'s non-parametric estimator \(\hat{\tau}_o\), Lakhal et al. (2009)'s inverse probability weighting (IPCW) estimators \(\hat{\tau}_{mo1}\) and \(\hat{\tau}_{mo2}\), and Okui et al. (2025)'s modified IPCW estimator \(\hat{\tau}_{so}\). \(\hat{\tau}_{so}\) can take into account tie data. Confidence intervals were based on jackknife standard errors with a normal approximation. Moreover, theses extensions of stratified estimators, \(\hat{\tau}_o^S\), \(\hat{\tau}_{mo1}^S\), \(\hat{\tau}_{mo1}^S\), \(\hat{\tau}_{so}^S\), are also available. Stratified estimators are based on (random-effects) meta-analysis models.

Usage

surrosurvo(
  y,
  event,
  x,
  eventx = NULL,
  censtype = c("univariate", "independent"),
  strata = NULL,
  level = 0.95,
  B = 25000,
  parallel = FALSE,
  seed = NULL
)

Arguments

y

the survival time or censoring time outcome vector

event

the event indicator outcome vector

x

the ordinal, continuous, or survival outcome vector

eventx

the event indicator outcome vector

censtype

the type of censoring model for survival and survival outcomes (default = "univariate"; see Lakhal et al. (2009)).

  • univariate: univariate censoring model: \(Y = \min(T, C)\), \(X = \min(T_X, C)\)

  • independent: independent censoring model: \(Y = \min(T, C)\), \(X = \min(T_X, C_X)\)

strata

the stratified variable vector

level

the confidence level of the confidence interval (default = 0.95)

B

the number of bootstrap samples

parallel

the number of threads used in parallel computing, or FALSE that means single threading (default = FALSE)

seed

set the value of random seed

Value

  • method: names for estimators of \(\hat{\tau}\)

  • tau: estimates \(\hat{\tau}\)

  • se: standard errors for \(\hat{\tau}\)

  • lcl: lower confidence limits \(\hat{\tau}_l\)

  • ucl: uper confidence limits \(\hat{\tau}_u\)

References

Oakes, D. (1982). A model for association in bivariate survival data. J R Stat Soc Ser B Methodol. 44(3): 414-422. https://doi.org/10.1111/j.2517-6161.1982.tb01222.x

Lakhal, L, Rivest, L-P., and Beaudoin, D. (2009). IPCW estimator for Kendall's tau under bivariate censoring. Int J Biostat. 5(1): Article 8. https://doi.org/10.2202/1557-4679.1121

Okui, J., Nagashima, K., Matsuda, S., et al (2025). Evaluation of pathological complete response as a surrogate endpoint for overall survival in resectable esophageal cancer. Br J Surg. 112(6)): znaf131. https://doi.org/10.1093/bjs/znaf131

See also

Examples

library(surrosurvo)
set.seed(1234)
data <- generate_rv(0.7, 300, 0.3)
surrosurvo(data$y, data$event, data$x)
#>   method       tau         se       lcl       ucl
#> 1 taumo1 0.6705591 0.02860693 0.6144905 0.7266276
#> 2 taumo2 0.6719080 0.01936183 0.6339595 0.7098565
#> 3   tauo 0.5268004 0.02155815 0.4845472 0.5690537
#> 4  tauso 0.7563231 0.03076103 0.6960326 0.8166137

# Parallel computation
surrosurvo(data$y, data$event, data$x, parallel = 2)
#>   method       tau         se       lcl       ucl
#> 1 taumo1 0.6705591 0.02860693 0.6144905 0.7266276
#> 2 taumo2 0.6719080 0.01936183 0.6339595 0.7098565
#> 3   tauo 0.5268004 0.02155815 0.4845472 0.5690537
#> 4  tauso 0.7563231 0.03076103 0.6960326 0.8166137