I did it like above  but got an error message.

> estimate<- optim(init.par,Linn,gr=NULL,method= "L-BFGS-B",
> hessian=FALSE,control =
> list(trace=1),lower=c(0,-Inf,Inf,Inf),upper=c(1,Inf,Inf,Inf))
Error in solve.default(sig[, , 1]) : 
  system is computationally singular: reciprocal condition number = 0

"how to derive constrain for only 1 variable"

Regards,
Ser

--
View this message in context: 
http://r.789695.n4.nabble.com/Optim-package-restriction-tp4418379p4418865.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to