tornadounc: Computes Correlation between Inputs and Output in a mc Object...

Description Usage Arguments Details Value See Also Examples

View source: R/tornadounc.mc.R

Description

Provides statistics for a tornado chart. Evaluates correlations between output and inputs of a mc object in the uncertainty dimension.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## S3 method for class 'mc'
tornadounc(mc, output=length(mc), quant=c(0.5, 0.75, 0.975), use="all.obs",
	  method=c("spearman", "kendall", "pearson"), ...)
## Default S3 method:
tornadounc(mc, ...)
## S3 method for class 'tornadounc'
print(x, ...)
## S3 method for class 'mccut'
tornadounc(mc, output=length(mc), quant=c(0.5, 0.75, 0.975), use="all.obs",
	  method=c("spearman", "kendall", "pearson"), ...)

Arguments

mc

a mc object.

x

a tornadounc object.

output

The rank or the name of the output to be considered. Should be a "VU" or a "U" type mcnode. By default: the last element of mc.

quant

The vector of quantiles used in the variability dimension.

use

An optional character string giving a method for computing covariances in the presence of missing values. This must be (an abbreviation of) one of the strings "all.obs", "complete.obs" or "pairwise.complete.obs" (see cor).

method

A character string indicating which correlation coefficient (or covariance) is to be computed. One of "spearman" (default), "kendall" or "pearson", can be abbreviated (see cor). Warning : "pearson" is the default for cor).

...

Further arguments to be passed to the final print function.

Details

The tornadounc.mc function computes the spearman's rho statistic between

The statistics are the mean, the median and the quantiles specified by quant.

It is useful to estimate a rank-based measure of association between one set of random variable of a mc object (the output) and the others in the uncertainty dimension.

tornadounc.mccut may be applied on a mccut object if a summary.mc function was used in the third block of the evalmccut call.

If output refers to a "0" or "V" mcnode, it is an error.

If use is "all.obs", then the presence of missing observations will produce an error. If use is "complete.obs" then missing values are handled by casewise deletion. Finally, if use has the value "pairwise.complete.obs" then the correlation between each pair of variables is computed using all complete pairs of observations on those variables.

Value

An invisible object of class tornadounc. A tornadounc object is a list of objects containing the following objects:

value

a matrix of values of correlation coefficients. Each row are the value or the statistics of inputs, each columns the value or the statistics of outputs.

output

the name of the output

method

the method used

use

the use parameter

See Also

cor.

tornado for tornado in the variability dimension.

plot.tornadounc to draw the results.

Examples

1
2
3
4
5
6
7
data(total)
tornadounc(total, 3)
tornadounc(total, 4, use="complete")
tornadounc(total, 7, use="complete.obs")
tornadounc(total, 8, use="complete.obs")
(y <- tornadounc(total, 10, use="complete.obs"))
plot(y, 1, 1)

mc2d documentation built on July 5, 2021, 5:09 p.m.