Learn R Programming

pgirmess (version 2.0.2)

cormat: Gives a correlation matrix and the probability of Ho for each correlation

Description

Gives a correlation matrix and the probability of Ho for each correlation estimate

Usage

cormat(donnees, method = "spearman", sep = FALSE)

Value

If sep = F (default) a list including:

method

The method used

prob.cor

Upper triangle, the correlations; lower triangle, the probability of Ho

If sep = T a list including:

method

The method used

coef.estimates

The correlation matrix

p.value

The Ho probability matrix

Arguments

donnees

a data frame of numerics

method

a string of characters among 'pearson', 'spearman' (default), 'kendall'

sep

If true, gives the results in two matrices (default = F)

Details

Wrapper for 'cor' and 'cor.test'. The results can be given in one or two matrices.

See Also

Examples

Run this code
cormat(longley)
cormat(longley,sep=TRUE)

Run the code above in your browser using DataLab