tornado: Computes Correlation Between Inputs and Output in the...

View source: R/tornado.R

tornadoR Documentation

Computes Correlation Between Inputs and Output in the Variability Dimension (Tornado)

Description

Provides statistics for a tornado chart. Evaluates correlations between output and inputs of a ‘⁠mc⁠’ object in the variability dimension.

Usage

tornado(
  mc,
  output = length(mc),
  use = "all.obs",
  method = c("spearman", "kendall", "pearson"),
  lim = c(0.025, 0.975)
)

## S3 method for class 'tornado'
print(x, ...)

Arguments

mc

a mc or mccut object.

output

the rank or name of the output to be considered. By default: the last element.

use

an optional character string for computing covariances in the presence of missing values: ‘⁠"all.obs"⁠’, ‘⁠"complete.obs"⁠’ or ‘⁠"pairwise.complete.obs"⁠’.

method

a character string for the correlation coefficient: ‘⁠"spearman"⁠’ (default), ‘⁠"kendall"⁠’ or ‘⁠"pearson"⁠’.

lim

a vector of quantiles used to compute the credible interval.

x

a ‘⁠tornado⁠’ object.

...

further arguments to be passed to the final print function.

Details

The tornado function computes Spearman's rho statistic to estimate a rank-based measure of association between one set of random variables of a ‘⁠mc⁠’ object (the output) and the others (the inputs).

‘⁠tornado⁠’ may be applied on a ‘⁠mccut⁠’ object if a ‘⁠tornado⁠’ function was used in the third block of the evalmccut call.

Type rules for the output node:

  • ‘⁠"V" mcnode⁠’: correlations are only provided for other ‘⁠"V" mcnode⁠’s.

  • ‘⁠"VU" mcnode⁠’: correlations are provided for other ‘⁠"VU"⁠’ and ‘⁠"V"⁠’ nodes.

Value

an invisible object of class ‘⁠tornado⁠’, containing: ‘⁠value⁠’ (correlation coefficients), ‘⁠output⁠’ (name of output), ‘⁠method⁠’, ‘⁠use⁠’.

See Also

cor, plot.tornado to draw the results.

Examples

data(total)
tornado(total, 2, "complete.obs", "spearman", c(0.025, 0.975))
(y <- tornado(total, 10, "complete.obs", "spearman", c(0.025, 0.975)))
plot(y)

mc2d documentation built on Oct. 23, 2026, 1:06 a.m.