lme4 - Calculating CIs of fixed effects using confint in R -


I want to bootstrap to obtain 95% CIS of my definitive effect in binary GLMM:

  m  

I've found that the confint () function is able to get it, so I specified the function Is: <

was function I was walking before deciding to terminate more than 8 hours. At the end, I returned the following warning message (X10):

  Warning message: 1: in (function (Fn, equal to, bottom = rep.int (-Inf, n), My name is upper: 1) Do I need to worry about these warning messages? If so, how can I deal with them? 2) Since it was still going on after 8 hours, I have a clue It does not matter how long it takes to function. Therefore, there should be some kind of progress bar while doing this function. Logic from BootMer, so I gave the argument. Progress = "txt", resulting in:  
  concept (m, method = "boot", boot.type = "basic", seed = 123, nsim = 1000, .progress = "txt" ")  

But this does not seem to work. Alternatively, if there are better ways to achieve the same goal, then I'm open for suggestions.

Thanks for any help

Here's an example:

  Library ("lme4") (t1 and lt; - system.time (GM1 & lt; - glam (cibind (event, size - event) ~ duration + (1 | herd), data = CBPP, family = binary)) ## user system has passed ## 0.188 0.000 0.186 Narnpars & lt; - length (getME (gm1, "theta")) nfixpars & lt; - length (Fiksif (GM 1) () T2 and LT; - System.time (c1 and lt; - context (GM1, method = "boot", nsim = 1000, p Iarm = (Anaranpiars + 1) :( Narnpers + Anfikspar), Kprgrej = "Tisititi"))) # # user system has passed ## 221.958 0.164 222.187  

Note that this Progress bar is only 80 characters long, so it grows only after every 1000/80 = 12 bootstrap iterations. If your original model took an hour to fit, you expect to see any progress-oriented activity after 12 hours. Should not ...

  (t3 <- system.time (c2 & lt); - 1) 1000 bootstrap reps are probably overkill - (1) - If your model fit is slow, you can probably get  appropriate  cis from the 200 bootstrap reps.  

I tried to do it with optimizer = "nloptwrap" well, hopefully it will speed things up. Although there is a flaw (see below).

  (t4 <-> system.time (gm1b & lt; - glam (cbind (event, size - event) ~ period + (1 | winch), data = cppp, family = Binomial control = glamor control (optimizer = "delete")) ## User System Elapsed ## 0.064 0.008 0.075 (T5 and LT; - System.time (C3 and LT; - (Gm1b, method = "boot ", nsim = 1000, parm = (nranpars + 1) :( naranpars + nfixpars), .progress =" txt ", PBargs = list (style = 3)))) #### user system has passed very fast ,  but  warns about convergence (37 in this case).  all.equal () According to , only 2% difference in confidence interval was done in this way. (There are still some wrinkles to solve the problem in the package ...) 

To speed it up Your best bet will be parallel to - unfortunately, in this way you lose the ability to use a progress bar ...

  (t6> - system.time (c4 and lt; - confint (gm1, method = "boot", nsim = 1000, parm = (nranpars + 1) :( Nrnpar + Nfixpars), parallel = "multicore" Anseepis = 4))) ## # sender cis Time elapsed ## 310.355 0.916 116.917  

This more user timing (calculates the time used on all the cores), but cut in half time (It would be good to do better with 4 cores, but it's still good to be fast twice. These are virtual cores on virtual Linux machines, may have a better performance in the real (non-virtual) core.)

nloptwrap and multicore combined I can reduce the time 91 seconds (User) / 36 seconds (pass).


Comments

Popular posts from this blog

java - Can't add JTree to JPanel of a JInternalFrame -

javascript - data.match(var) not working it seems -

javascript - How can I pause a jQuery .each() loop, while waiting for user input? -