Aim:- To find the maximum likelihood estimators of µ and

Problem:- Obtain the estimators of µ and by the method of Maximum likelihood.

R- Code:-
> library(EstimationTools)
> maxlogL(x, dist, optimizer, lower = NULL, upper = NULL)
> set.seed(1000)
> z <- rnorm(n = 1000, mean = 10, sd = 1)
> fit1 <- maxlogL(x = z, dist = 'dnorm', start=c(2, 3),
+ lower=c(-15, 0), upper=c(15, 10))
> summary(fit1)
Inference:-
--------------------------------------------------------------
Optimization routine: nlminb
Standard Error calculation: Hessian from optim
---------------------------------------------------------------
AIC BIC
2804.033 2800.033
---------------------------------------------------------------
Estimate Std. Error
mean 9.98752 0.0310
sd 0.98126 0.0219

Aim:- To find the maximum likelihood estimator of the parameter p.

Problem:- Obtain the maximum likelihood estimator of the parameter p in binomial
distribution.
> set.seed(100)
> N <- rbinom(n = 100, size = 10, prob = 0.3)
> phat <- maxlogL(x = N, dist = 'dbinom', fixed = list(size = 10),
+ link = list(over = "prob", fun = "logit_link"))
> summary(phat)
Optimization routine: nlminb
Standard Error calculation: Hessian from optim
---------------------------------------------------------------
AIC BIC
334.9805 334.9805
---------------------------------------------------------------
Estimate Std. Error
prob 0.312 0.0147