From: <li...@us...> - 2011-12-30 18:51:55
|
Revision: 239 http://bugs-r.svn.sourceforge.net/bugs-r/?rev=239&view=rev Author: ligges Date: 2011-12-30 18:51:49 +0000 (Fri, 30 Dec 2011) Log Message: ----------- rev 211 broke samplesHistory and removed its capability to work on more than just a scalar note. This is a worakround to enable the feature again Revision Links: -------------- http://bugs-r.svn.sourceforge.net/bugs-r/?rev=211&view=rev Modified Paths: -------------- trunk/BRugs/R/samples.history.R Modified: trunk/BRugs/R/samples.history.R =================================================================== --- trunk/BRugs/R/samples.history.R 2011-12-30 18:39:49 UTC (rev 238) +++ trunk/BRugs/R/samples.history.R 2011-12-30 18:51:49 UTC (rev 239) @@ -4,7 +4,13 @@ thin = samplesGetThin(), plot = TRUE, mfrow = c(3, 1), ask = NULL, ann = TRUE, ...) # Plot history { - if (samplesSize(node)==0) stop("No monitored samples available") + sM <- samplesMonitors(node)[1] + if(sM == "model must be initialized before monitors used") + stop("model must be initialized / updated / monitored before samplesSample is used") + if(length(grep("^no monitor set for variable", sM))) + stop(sM) + if (samplesSize(sM[1])==0) + stop("No monitored samples available") if(plot && is.null(ask)) { if (is.R()) ask <- !((dev.cur() > 1) && !dev.interactive()) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |