Calculates correlations and associated p-values for two ensemble matrices (or vectors)

corMatrix(
  ens.1,
  ens.2,
  max.ens = NA,
  isospectral = TRUE,
  isopersistent = FALSE,
  p.ens = 100,
  gaussianize = TRUE,
  cor.method = "pearson"
)

Arguments

ens.1

matrix of age-uncertain columns to correlate and calculate p-values

ens.2

matrix of age-uncertain columns to correlate and calculate p-values

max.ens

optionally limit the number of ensembles calculated (default = NA)

isospectral

estimate significance using the Ebisuzaki method (default = TRUE)

isopersistent

estimate significance using the isopersistence method (default = FALSE)

p.ens

number of ensemble members to use for isospectral and/or isopersistent methods (default = 100)

gaussianize

Boolean flag indicating whether the values should be mapped to a standard Gaussian prior to analysis.

cor.method

correlation method to pass to cor() "pearson" (default), "kendall", or "spearman". Note that because the standard Student's T-test for significance is inappropriate for Kendall's Tau correlations, the raw and effective-N significance estimates will be NA when using "kendall"

Value

out list of correlation coefficients (r) p-values (p) and autocorrelation corrected p-values (pAdj)

See also

Author

Nick McKay

Julien Emile-Geay