Hello: I recently asked the list a question regarding warning.expression. This is a different statement of the problem.
I am doing a large simulation experiment using nlme and most of the data realizations run fine. The simulations stall, however, on a few particularly noisy data sets. What happens is that the nlme function initially calls the nlm function and some code in there generates an endless number of warning messages. These are: "Warning: Singular precision matrix in level ...". Becuse of this, my simulation is caught in an endless loop and after quite a while R crashes. I do use try(nlme(...)), so if I could find a way to flag these warning and make them into errors, such as by calling stop(), then my code could move on to the next realizaton of the simulation. Some warnings are produced that are not endless or otherwise problematic, so I do not want to cause an error for every warning. Does anyone have any ideas as to how to identify warning messages and call stop() or otherwise induce an error if the warnings are of a particular type? John ______________________________________________ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
