The lmerControl
function allows you to choose an optimizer and pass controls parameters to it. The parameters that control numbers of iterations or evaluations vary from function to function (as described in the help page for lmerControl
). The default optimizer is "Nelder_Mead" and for that optimizer choice the maximum number of evaluations can be changed by specifying "maxfun" in the 'optCtrl' parameter list:
m <- lmer(RT ~ Factor1*Factor2 + (0+Factor1+Factor2|Subject) +
(1|Subject) + (1|Item) + (0+Factor1+Factor2|Item),
data= data, control=lmerControl(optCtrl=list(maxfun=20000) ) )
This is not a guarantee that convergence will be reached. (My experience is that the default maximum is usually sufficient.) It's perfectly possible that your data is insufficient to support the complexity of the model or the model is incorrectly constructed for the design of the study.
And belated thanks to @NBrouwer for his note to extend this advice to glmer
with glmControl
.