plot2Densities {ImpactEffectsize}R Documentation

Plotting the propability densitiy functions of two groups

Description

plots the pdf of the two groups as Pareto density estimation.

Usage

plot2Densities(Data,Cls,col=c("red","blue"), pde=TRUE, 
	meanLines=FALSE,medianLines=FALSE,...)

Arguments

Data

The data of both groups as a vector.

Cls

The class information as a vector of similar length as the data vector.

col

Colors of the two lines to plot.

pde

Plots a standard pdf insted of a non-parametric Pareto density estimation.

meanLines

Adds perpendicular lines at the means of the two groups.

medianLines

Adds perpendicular lines at the medians of the two groups.

...

More graphical parameters can be entered as plot arguments if PlotIt = TRUE.

Author(s)

Jorn Lotsch and Alfred Ultsch

References

Lotsch, J., and Ultsch, A. (2019): Impact – an R Package for calculation and visualisation of the Impact distance and shape based effect size measure.

Examples

## example 1
nrPerClass = 100
SampleImpact  = c()
SampleClasses = rep(c(1,2), each=nrPerClass)

SampleData = matrix(ncol=100, nrow=200)

for(i in 1:100){
  SampleVector = c(rnorm(nrPerClass, 1, 5), 
               rnorm(nrPerClass, i, 5)) 
  SampleData[,i] = SampleVector
  SampleImpact[i] = Impact(SampleVector, SampleClasses)$Impact
}
plot(SampleImpact, type='l', main=("Impact: \nIncreasing difference in means"))

[Package ImpactEffectsize version 0.5.0 Index]