Re: [R] using optimize with two unknowns, e.g. to parameterize a distribution with given confidence interval

2010-10-19 Thread Ravi Varadhan
nf")) optimx(par=c(1,10), fn=prior, mean=0, var=1, alpha=0.05, method=c("Nelder", "BFGS", "CG", "spg", "bobyqa", "Rvmmin", "nlminb", "Rcgmin", "ucminf")) Hope this helps, Ravi. -Original M

Re: [R] using optimize with two unknowns, e.g. to parameterize a distribution with given confidence interval

2010-10-16 Thread Ben Bolker
David LeBauer illinois.edu> writes: > > Hi, > > I would like to write a function that finds parameters of a log-normal > distribution with a 1-alpha CI of (x_lcl, x_ucl): > > However, I don't know how to optimize for the two unknown parameters. > Try optim instead. ___

[R] using optimize with two unknowns, e.g. to parameterize a distribution with given confidence interval

2010-10-15 Thread David LeBauer
Hi, I would like to write a function that finds parameters of a log-normal distribution with a 1-alpha CI of (x_lcl, x_ucl): However, I don't know how to optimize for the two unknown parameters. Here is my unsuccessful attempt to find a lognormal distribution with a 90%CI of 1,20: prior <- func