x <- 0:10
y <- c(26, 17, 13, 12, 20, 5, 9, 8, 5, 4, 8)
fit1 <- mle2(y~dpois(lambda=ymax/(1+x/xhalf)),start=list(ymax=1,xhalf=1),
method="L-BFGS-B",lower=c(0.001,0.001))
p1 <- profile(fit1)
plot(p1,main=c("first","second"),
xlab=c(~y[max],~x[1/2]),ylab="Signed square root deviance")Run the code above in your browser using DataLab