Skip to content

question about optim

3 messages · chirine wolley, Ben Bolker

#
chirine wolley <wolley.chirine <at> hotmail.com> writes:
suppose the dimensions of X are (Xc,Xr)
and the dimensions of x3 (I can't easily figure out what they should
be) are (m,n)
x3 <- matrix(x[(Xc+2):(Xc+1+m*n)],nrow=m,ncol=n)
  ## be careful about column- vs row-encoding, possibly use byrow=TRUE

x4 <- x[(Xc+1+m*n+1):length(x)] #4th paramater is a vector
to call optim(), concatenate reasonable initial guesses for your
parameters. (I have no idea what 'c' is in your code below ...)
1 day later