# STA 410/2102, Fall 2015, Script for Assignment #2, Problem 1. source("ass2p1-funs.r") # Set the sample sizes and observed counts for the data in the Assignment #1 # handout. n <- 130 m1 <- 25 m2 <- 25 x <- 75 x1 <- 20 x2 <- 6 # Run EM. options(digits=17) initial <- c(x1/m1,x2/m2) # initial parameter values print (mle_em (n,m1,m2,x,x1,x2,initial,95))