Learn R Programming

MineICA (version 1.12.0)

plotMclust: Plots the Gaussian fitted by Mclust

Description

Given a result of function Mclust applied on a numeric vector, this function add the fitted Gaussian to a previous plot. This is an internal function called by plotPosSamplesInComp.

Usage

plotMclust(mc, data)

Arguments

mc
The result of Mclust function applied to argument data
data
The vector of numeric values on which was applied Mclust

Value

NULL

Details

This function can only deal with at the most three Gaussian.

Examples

Run this code
## create a mix of two Gaussian
v <-c(rnorm(80,mean=-0.5,sd=1),rnorm(80,mean=1,sd=0.2))
## apply Mclust
mc <- Mclust(v)
## plot fitted Gaussian on histogram of v
hist(v, freq=FALSE)
MineICA:::plotMclust(mc=mc,data=v)

Run the code above in your browser using DataLab