Mest: E-Step For Mean Estimate

Description Usage Arguments Value Examples

Description

E-Step For Mean Estimate

Usage

1
mest(theta, bl, bu, freq)

Arguments

theta

Initial theta value, vector containing mean and sd.

bl

Lower bound of the intervals, values in vector, starting from -inf.

bu

Upper bound of the intervals, values in vector, ending with +inf.

freq

frequency over the intervals, values in vector.

Value

Return M which are the estimates of mean in E-step.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
 library(em.univ)
 library(stats)
 
 simdataaaa <- em.univ::univ_simul(ncol_matrix=1,
                         n=50,
                         nclass = 10,
                         mean = 68,
                         sd = 1.80,
                         fr_breaks=c(62,64,66,68,70,72,74,76,78))
 
 munew <- em.univ::mest(theta=c(67,2),
               bl=simdataaaa$simul_data[,1,1],
               bu=simdataaaa$simul_data[,2,1],
               freq=simdataaaa$simul_data[,3,1])
 
 
 munew

JoaoPedro2536/univ.em documentation built on Dec. 18, 2021, 1:38 a.m.