exact_mle: Maximizing the Likelihood Estimation 1.

Description Usage Arguments Value Examples

View source: R/em_mcem_logll.R

Description

Maximizing the Likelihood Estimation 1.

Usage

1
2
3
4
5
6
exact_mle(
  tl = c(-Inf, 62, 64, 66, 68, 70, 72, 74, 76, 78),
  freq = c(0, 1, 9, 16, 15, 8, 1, 0, 0, 0),
  intial_mu = (67/2),
  intial_sigma = (1/2)
)

Arguments

tl

Lower end of the intervals.

freq

Frequency on each interval.

intial_mu

Initial numeric value for mu (mean).

intial_sigma

Initial numeric value for sigma.

Value

Return the result of the log likelihood for the mean (mu) and sigma (variance) estimates.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
 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))
 
 
 tl<- simdataaaa$simul_data[,1,1]
 freq<- simdataaaa$simul_data[,3,1]
 
 estimates_simul <- em.univ::exact_mle(tl=tl,
                             freq=freq,
                             intial_mu = (67/2),
                             intial_sigma = (1/2))
 
 estimates_simul

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