Skip to content

all_fit nmkbw does not work, when afex is not attached #62

@singmann

Description

@singmann

I intend to fix later.

library("lme4")
library("optimx")
gm1 <- glmer(cbind(incidence, size - incidence) ~ period + (1 | herd),
             data = cbpp, family = binomial)

gm_all <- afex::all_fit(gm1)
!sapply(gm_all,inherits,"error") 
#                       bobyqa.                  Nelder_Mead. 
#                          TRUE                          TRUE 
#                 optimx.nlminb               optimx.L-BFGS-B 
#                          TRUE                          TRUE 
# nloptwrap.NLOPT_LN_NELDERMEAD     nloptwrap.NLOPT_LN_BOBYQA 
#                          TRUE                          TRUE 
#                        nmkbw. 
#                         FALSE 

gm_all[["nmkbw."]]
## <simpleError in getOptfun(optimizer): couldn't find optimizer function nmkbw>

library("afex")
gm_all <- all_fit(gm1)
!sapply(gm_all,inherits,"error") 
#                       bobyqa.                  Nelder_Mead. 
#                          TRUE                          TRUE 
#                 optimx.nlminb               optimx.L-BFGS-B 
#                          TRUE                          TRUE 
# nloptwrap.NLOPT_LN_NELDERMEAD     nloptwrap.NLOPT_LN_BOBYQA 
#                          TRUE                          TRUE 
#                        nmkbw. 
#                          TRUE 

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions