powered by
Returns the Kolmogorov-Smirnov and Anderson-Darling test statistics for two right-censored data sets.
twosamplesurvpvs(times, delta, grp, nmc = 10000, plotme = TRUE, exact = FALSE)
A vector of length two, with the Kolmogorov-Smirnov and Anderson-Darling statistics.
Event and censoring times
Indicator of event (1) or censoring (0).
Variable that divides the population into groups.
Number of Monte Carlo samples for p value calculation
logical; indicates whether to plot or not.
logical; indicates whether to use exhaustive enumeration of permutations or not.
The function calls a Fortran code to calculate the estimators b and their variance-covariance matrix Vb
b
Vb
twosamplesurvpvs(rexp(20),rbinom(20,1,.5),rbinom(20,1,.5))
Run the code above in your browser using DataLab