Skip to content

Printing progress information to screen

Brian Lau edited this page Aug 3, 2015 · 2 revisions

Sampling progress can be monitored a couple of ways. You can set the verbose property of a fit object true, which will print sampler info to the screen periodically. If this is too much information, you can also use the check() method, which will simply tell you whether all chains have finished sampling.

fit = stan('file','rats.stan','data',rats_dat,'iter',50000);

% print periodic sampler info to screen
fit.verbose = true;

% Too much info, just want to check whether chains have finished sampling
fit.verbose = false;
fit.check();

More advanced checking can be implemented using listeners to notify when sampling is complete.