Learn R Programming

eqs2lavaan (version 3.0)

plotCov: Plot a Covariance/Correlation Heat Map

Description

Any covariance matrix can be entered and an image with covariance and correlation matrices will be plotted.

Usage

plotCov(cov)

Arguments

cov
A covariance matrix.

Value

An image containing heat map based items for the covariance and resulting correlation matrix.

See Also

eqsCov eqsCorr eqsDesc cor2cov

Examples

Run this code
library(datasets)
plotCov(ability.cov$cov)
plotCov(cov(attitude))

library(lavaan)
HolzingerSwineford1939
# Select variables x1-x9 only
HS39 <- cov(HolzingerSwineford1939[,7:15])
plotCov(HS39)

Run the code above in your browser using DataLab