R Under development (unstable) (2023-12-07 r85661 ucrt) -- "Unsuffered Consequences" Copyright (C) 2023 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 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(bbmle) Loading required package: stats4 > x <- 0:10 > y <- c(26, 17, 13, 12, 20, 5, 9, 8, 5, 4, 8) > d <- data.frame(x,y) > > ## uses default parameters of LL > fit <- mle2(y~dpois(exp(loglam)), + data=d, + start=list(loglam=0),control=list(maxit=2)) Warning message: In mle2(y ~ dpois(exp(loglam)), data = d, start = list(loglam = 0), : convergence failure: code=1 (iteration limit 'maxit' reached) > pp <- profile(fit) Profiling has found a better solution,so original fit had not converged: (new deviance=252, old deviance=272.7, diff=-20.78) Returning better fit ... > > proc.time() user system elapsed 1.65 0.12 1.75