AdaptGauss {AdaptGauss} | R Documentation |
Adapt Gaussian Mixture Model (GMM)
Description
Adapt interactively a Gaussians Mixture Model GMM to the empirical PDF of the data (generated by DataVisualizations::ParetoDensityEstimation) such that N(Means,SDs)*Weights is a model for Data
Usage
AdaptGauss(Data, Means = NaN, SDs = NaN, Weights = NaN,
ParetoRadius = NaN, LB = NaN, HB = NaN,
ListOfAdaptGauss, fast = T)
Arguments
Data |
Data for empirical PDF. Has to be an Array of values. NaNs and NULLs will be deleted |
Means |
Optional: Means of gaussians of GMM. |
SDs |
Optional: StandardDevations of gaussians of GMM. (Has to be the same length as Means) |
Weights |
Optional: Weights of gaussians of GMM. (Has to be the same length as Means) |
ParetoRadius |
Optional: Pareto Radius of Pareto Desity Estimation (PDE). |
LB |
Optional: Low boundary of estimation. All values below LB will be deleted. Default: min(Data) |
HB |
Optional: High boundary of estimation. All values above HB will be deleted. Default: max(Data) |
ListOfAdaptGauss |
Optional: If editing of an existing Model is the goal, enables to give the Output of AdaptGaus as the Input of AdaptGauss() instead of setting Means, SDs and Weights separately |
fast |
Default=TRUE; FALSE: Using mclust's EM see function |
Details
Data: maximum length is 10000. If larger, Data will be randomly reduced to 10000 Elements. MeansIn/DeviationsIn/WeightsIN: If empty, either one or three Gaussian's are generated by kmeans algorithm. Pareto Radius: If empty: will be generated by DataVisualizations::ParetoDensityEstimation RMS: Root Mean Square error is normalized by RMS of Gaussian's with Mean=mean(data) and SD=sd(data), see [Ultsch et.al., 2015] for further details.
Value
List with
Means |
Means of Gaussian's. |
SDs |
Standard SDs of Gaussian's. |
Weights |
Weights of Gaussian's. |
ParetoRadius |
Pareto Radius: Either ParetoRadiusIn, the pareto radius enerated by PretoDensityEstimation(if no Pareto Radius in Input). |
RMS |
Root Mean Square of Deviation between Gaussian Mixture Model GMM to the empirical PDF. Normalized by RMS of one Gaussian with mean=meanrobust(data) and sdev=stdrobust(data). Further Details in [Ultsch et al 2015] |
BayesBoundaries |
vector[1:L-1], Bayes decision boundaries |
Author(s)
Onno Hansen-Goos, Michael Thrun
References
Ultsch, A., Thrun, M.C., Hansen-Goos, O., Loetsch, J.: Identification of Molecular Fingerprints in Human Heat Pain Thresholds by Use of an Interactive Mixture Model R Toolbox(AdaptGauss), International Journal of Molecular Sciences, doi:10.3390/ijms161025897, 2015.
Thrun M.C., Ultsch, A.: Models of Income Distributions for Knowledge Discovery, European Conference on Data Analysis, DOI 10.13140/RG.2.1.4463.0244, Colchester 2015.
Examples
data1=c(rnorm(1000))
## Not run: Vals1=AdaptGauss(data1)
data2=c(rnorm(1000),rnorm(2000)+2,rnorm(1000)*2-1)
## Not run: Vals2=AdaptGauss(data2,c(-1,0,2),c(2,1,1),c(0.25,0.25,0.5),0.3,-6,6)