Dear List, I am getting a lot of pwrssUpdate errors when trying to model my data with gmler (using the most recent version from svn... I don't know if the previous versions were affected). These errors are "PIRLS step failed" or "pwrssUpdate did not converge in 30 iterations". I understand that these means that the algorithm does not manage to work with my data, but there is a peculiar behavior, and my data doesn't seem too unreasonable to fit with the model I want to use, so I am wondering if the problem is on my side ! Here is a link toward a plot of part of my data as I want to model it (using ggplot2) : https://dl.dropbox.com/u/1205127/Images/glmer_plot.pdf Each panel is for a subject of a behavioral experiment, and what is represented is the probability of the subject following a rule as a function of the weight given to this rule in the instructions (RuleWeight, between 0 and 1 here). Each point corresponds to a probability computed over 6 trials (points are jittered to see better). Here is the model I want to fit, which doesn't seem unreasonable given the figure (random slopes and intercepts for subjects) : model<-glmer(cbind(RuleReach,NTrials-RuleReach)~RuleWeight+(RuleWeight|Subject),data=rewardalldirsub,family=binomial) However this gives me the "pwrssUpdate did not converge in 30 iterations" error. What is surprinsing, is that if I do not use the rightmost points (RuleWeight of 1), the model converges, even though there are less datapoints and the remaining points are the noisiest (subjects follow the rule quite reliably when it has a weight of 1 as you can see). Removing the correlation in the random effects works sometimes (but not on all my sub data sets), and having a random intercept only (which is obviously not correct) is the only thing that seems to work in all cases. Centering RuleWeight (ie having it between -1 and 1 instead of 0 and 1) doesn't work. Any ideas on why this doesn't work / how to make it work ? Thanks Pierre Morel
Avoid errors in pwrssUpdate ?
4 messages · Ben Bolker, Pierre Morel, Ken Knoblauch
Pierre Morel <pier.morel at ...> writes:
I am getting a lot of pwrssUpdate errors when trying to model my data with gmler (using the most recent version from svn... I don't know if the previous versions were affected).
These errors are "PIRLS step failed" or "pwrssUpdate did not converge in 30 iterations". I understand that these means that the algorithm does not manage to work with my data, but there is a peculiar behavior, and my data doesn't seem too unreasonable to fit with the model I want to use, so I am wondering if the problem is on my side !
[snip to make gmane happier]
Here is the model I want to fit, which doesn't seem unreasonable given the figure (random slopes and intercepts for subjects) :
model<-glmer(cbind(RuleReach,NTrials-RuleReach)~RuleWeight+ (RuleWeight|Subject),data=rewardalldirsub,family=binomial)
However this gives me the "pwrssUpdate did not converge in 30 iterations" error. What is surprinsing, is that if I do not use the rightmost points (RuleWeight of 1), the model converges, even though there are less datapoints and the remaining points are the noisiest (subjects follow the rule quite reliably when it has a weight of 1 as you can see).
Removing the correlation in the random effects works sometimes (but not on all my sub data sets), and having a random intercept only (which is obviously not correct) is the only thing that seems to work in all cases.
Centering RuleWeight (ie having it between -1 and 1 instead of 0 and 1) doesn't work. Any ideas on why this doesn't work / how to make it work ?
Thanks for the report: this is an issue the developers are (painfully) aware of, and working on. The issue arises mostly when the predictions for some observations are very close to 0 or 1 (which explains why using the rightmost points helps ...) You have tried all the obvious things I know of. I would additionally try (1) setting starting values by hand and/or (2) trying out glmmADMB ... Ben Bolker
OK, thanks for the suggestion of glmmADMB, I will look that up. I also found out that I could get things working with nAGQ=0. However the doc says it's less exact, and profile() gives a "pp$setTheta(theta) : theta size mismatch" error in this case. Pierre Morel Le 13 juin 2012 ? 10:54, Ben Bolker a ?crit :
Pierre Morel <pier.morel at ...> writes:
I am getting a lot of pwrssUpdate errors when trying to model my data with gmler (using the most recent version from svn... I don't know if the previous versions were affected).
These errors are "PIRLS step failed" or "pwrssUpdate did not converge in 30 iterations". I understand that these means that the algorithm does not manage to work with my data, but there is a peculiar behavior, and my data doesn't seem too unreasonable to fit with the model I want to use, so I am wondering if the problem is on my side !
[snip to make gmane happier]
Here is the model I want to fit, which doesn't seem unreasonable given the figure (random slopes and intercepts for subjects) :
model<-glmer(cbind(RuleReach,NTrials-RuleReach)~RuleWeight+ (RuleWeight|Subject),data=rewardalldirsub,family=binomial)
However this gives me the "pwrssUpdate did not converge in 30 iterations" error. What is surprinsing, is that if I do not use the rightmost points (RuleWeight of 1), the model converges, even though there are less datapoints and the remaining points are the noisiest (subjects follow the rule quite reliably when it has a weight of 1 as you can see).
Removing the correlation in the random effects works sometimes (but not on all my sub data sets), and having a random intercept only (which is obviously not correct) is the only thing that seems to work in all cases.
Centering RuleWeight (ie having it between -1 and 1 instead of 0 and 1) doesn't work. Any ideas on why this doesn't work / how to make it work ?
Thanks for the report: this is an issue the developers are (painfully) aware of, and working on. The issue arises mostly when the predictions for some observations are very close to 0 or 1 (which explains why using the rightmost points helps ...) You have tried all the obvious things I know of. I would additionally try (1) setting starting values by hand and/or (2) trying out glmmADMB ... Ben Bolker
_______________________________________________ R-sig-mixed-models at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
Pierre Morel <pier.morel at ...> writes:
OK, thanks for the suggestion of glmmADMB, I will look that up. I also found out that I could get things working with nAGQ=0. However the doc says it's less exact, and profile() gives
a "pp$setTheta(theta) : theta size mismatch"
error in this case. Pierre Morel Le 13 juin 2012 ? 10:54, Ben Bolker a ?crit :
Pierre Morel <pier.morel at ...> writes:
I am getting a lot of pwrssUpdate errors when trying to model my data with gmler (using the most recent version from svn... I don't know if the previous versions were affected). These errors are "PIRLS step failed" or "pwrssUpdate did not converge in 30 iterations". I understand that these means that the algorithm does not manage to work with my data, but there is a peculiar behavior, and my data doesn't seem too unreasonable to fit with the model I want to use, so I am wondering if the problem is on my side !
[snip to make gmane happier]
Here is the model I want to fit, which doesn't seem unreasonable given the figure (random slopes and intercepts for subjects) :
model<-glmer(cbind(RuleReach,NTrials-RuleReach)~RuleWeight+ (RuleWeight|Subject),data=rewardalldirsub,family=binomial)
However this gives me the "pwrssUpdate did not converge in 30 iterations" error. What is surprinsing, is that if I do not use the rightmost points (RuleWeight of 1), the model converges, even though there are less datapoints and the remaining points are the noisiest (subjects follow the rule quite reliably when it has a weight of 1 as you can see).
Removing the correlation in the random effects works sometimes (but not on all my sub data sets), and having a random intercept only (which is obviously not correct) is the only thing that seems to work in all cases.
Centering RuleWeight (ie having it between -1 and 1 instead of 0 and 1) doesn't work. Any ideas on why this doesn't work / how to make it work ?
Thanks for the report: this is an issue the developers are (painfully) aware of, and working on. The issue arises mostly when the predictions for some observations are very close to 0 or 1 (which explains why using the rightmost points helps ...) You have tried all the obvious things I know of. I would additionally try (1) setting starting values by hand and/or (2) trying out glmmADMB ... Ben Bolker
I've been trying to monitor this situation from afar so as not to harass the developers (unduly, at least), in order to be able to use the links from the psyphy package to fit psychometric functions for binary and aggregated responses when there are multiple-alternative forced choices. I did have some interaction with Pr. Bates on the topic a few months back and he did something around revision 1701 that does permit the link functions to work without emitting the PIRLS error, and so I keep this version around in a separate directory while checking the latest to see if the above discussed problem has been solved. So, it may be of value to try this earlier version, unless the developers provide strong reasons not to. Hope that is useful. Ken
Ken Knoblauch Inserm U846 Stem-cell and Brain Research Institute Department of Integrative Neurosciences 18 avenue du Doyen L?pine 69500 Bron France tel: +33 (0)4 72 91 34 77 fax: +33 (0)4 72 91 34 61 portable: +33 (0)6 84 10 64 10 http://www.sbri.fr/members/kenneth-knoblauch.html