search for: hetprobit

Displaying 1 result from an estimated 1 matches for "hetprobit".

Did you mean: getprofit
2004 Sep 21
1
Problems with boot and optim
...ap it with the sample command and a loop, but then the analysis in the next step isn't as nice The code for the likelihood and the call to boot is below. I have tried numerous other permutations as well. I am using R 1.9.1 on Windows XP pro. Thanks Luke Keele #Define Likelihood lik.hetprobit <-function(par, X, Y, Z){ #Pull Out Parameters Y <- as.matrix(y) X <- as.matrix(x) Z <- as.matrix(z) K <-ncol(X) M <-ncol(Z) b <- as.matrix(par[1:K]) gamma <- as.matrix(par[K+1:M]) mu <- (X%*%b) sd <- exp(Z%*%gamma) mu.sd <-(mu/sd) #Form Likelihood log....