This function performs iterative conditional modes to obtain
maximum a posteriori estimates for β (covariate coefficients),
w (latent abundances), and P (the precision matrix).
Usage
estimate(mfit)
Arguments
mfit
- a MInt model object.
Value
A MInt model object with the following attributes:
optim
List containing optimization details
optim$lambda
Value of the L1 penalty used during optimization
data
List containing the raw data
data$design
File path of the design matrix
data$response
File path of the response matrix
data$fmla
Formula used to model each response in terms of the design variables
data$y
Raw numerical data for the response matrix
data$xd
Design matrix in categorical form
data$x
Design matrix in numerical form
param
List containing parameter estimates
param$beta
p-covariates x o-responses matrix of regression coefficients
param$w
n-samples x o-responses matrix of latent abundances
param$P
o-responses x o-responses precision matrix
Examples
x <- system.file("extdata", "x.txt", package="MInt");
y <- system.file("extdata", "y.txt", package="MInt");
m <- mint(y,x,fmla = ~feature1 + feature2)
m <- estimate(m)
Results
R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
> library(MInt)
Loading required package: glasso
Loading required package: trust
Loading required package: MASS
Loading required package: testthat
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/MInt/estimate.Rd_%03d_medium.png", width=480, height=480)
> ### Name: estimate
> ### Title: Estimate parameters
> ### Aliases: estimate
>
> ### ** Examples
>
> x <- system.file("extdata", "x.txt", package="MInt");
> y <- system.file("extdata", "y.txt", package="MInt");
> m <- mint(y,x,fmla = ~feature1 + feature2)
> m <- estimate(m)
Iteration: 1 max(deltaP): 0.067014 Objective: -1061.913 Converged: FALSE
Iteration: 2 max(deltaP): 0.015160 Objective: -1061.823 Converged: FALSE
Iteration: 3 max(deltaP): 0.003953 Objective: -1061.813 Converged: FALSE
Iteration: 4 max(deltaP): 0.001160 Objective: -1061.806 Converged: FALSE
Iteration: 5 max(deltaP): 0.000396 Objective: -1061.8 Converged: FALSE
Iteration: 6 max(deltaP): 0.000181 Objective: -1061.793 Converged: FALSE
Iteration: 7 max(deltaP): 0.000122 Objective: -1061.787 Converged: FALSE
Iteration: 8 max(deltaP): 0.000114 Objective: -1061.78 Converged: FALSE
Iteration: 9 max(deltaP): 0.000111 Objective: -1061.774 Converged: FALSE
Iteration: 10 max(deltaP): 0.000109 Objective: -1061.767 Converged: FALSE
Iteration: 11 max(deltaP): 0.000108 Objective: -1061.761 Converged: FALSE
Iteration: 12 max(deltaP): 0.000107 Objective: -1061.755 Converged: FALSE
Iteration: 13 max(deltaP): 0.000106 Objective: -1061.749 Converged: FALSE
Iteration: 14 max(deltaP): 0.000105 Objective: -1061.743 Converged: FALSE
Iteration: 15 max(deltaP): 0.000104 Objective: -1061.737 Converged: FALSE
Iteration: 16 max(deltaP): 0.000103 Objective: -1061.731 Converged: FALSE
Iteration: 17 max(deltaP): 0.000102 Objective: -1061.725 Converged: FALSE
Iteration: 18 max(deltaP): 0.000101 Objective: -1061.719 Converged: FALSE
Iteration: 19 max(deltaP): 0.000100 Objective: -1061.713 Converged: TRUE
>
>
>
>
>
> dev.off()
null device
1
>