Usage
correlate(X, Y, method = c("pearson", "spearman", "kendall", "frequency", "cramersv",
"cindex"),strata, weights, outX = TRUE, bootstrap_count = 0, alpha = 0.05,
alternative = c("two.sided", "less", "greater"))
Arguments
X
Vector of type {numeric, ordered factor, or Surv}.
Y
Vector of type {numeric, ordered factor, or Surv} of same length as X
.
method
One of the following values: {pearson, spearman, kendall, frequency, cramersv, or cindex}.
strata
Vector of type {factor} corresponding to the sample strata.
weights
Vector of type {numeric} corresponding to the sample weights.
outX
For cindex, if set to TRUE
, ignore ties; otherwise, take them into account when computing the concordance index.
bootstrap_count
If set to 0
, analytical standard error for the correlation estimate in each strata is used to compute the meta-estimate (inverse-variance weighting avarega); otherwise a number of bootstraps are used to computes standard errors.
alpha
The probability of Type I error that is, rejecting a null hypothesis when it is in fact true
alternative
a character string specifying the alternative hypothesis,must be one of {two.sided (default), greater or less}. You can specify just the initial letter.