Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

densityPlot

Draw Smoothed Kernel density plot


Description

Draw Smoothed Kernel density plot

Usage

densityPlot(
  x,
  sig = 0.05,
  digits = 3,
  xlab = "Indirect effect(ab)",
  ylab = NULL
)

Arguments

x

A numeric vector

sig

significant level. Default value is 0.05

digits

Integer indicating the number of decimal places

xlab

character. x axis label

ylab

character. y axis label

Examples

require(lavaan)
labels=list(X="cond",M="pmi",Y="reaction")
model=tripleEquation(labels=labels)

set.seed(1234)
semfit=sem(model,data=pmi,se="boot",bootstrap=100)
bootData=getBootData(semfit)
bootData$indirect=bootData$a*bootData$b
densityPlot(bootData$indirect)

processR

Implementation of the 'PROCESS' Macro

v0.2.6
GPL-2
Authors
Keon-Woong Moon [aut, cre], Sokyoung Hong [ctb]
Initial release
2021-1-5

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.