[R-sig-hpc] snow/snowfall: outputting iteration number

Vinh Nguyen vqnguyen at uci.edu
Sat Nov 21 21:59:28 CET 2009

hmm, tried message(iter) in my wrapper function, and nothing get's printed.

my wrapper function is named Iteration() and takes in the iteration
number as it's argument, and get's executed in snowfall as:
result <- sfLapply( 1:nsim, Iteration, n=100)

any other suggestions?


On Sat, Nov 21, 2009 at 2:28 AM, Brian G. Peterson <brian at braverock.com> wrote:
> Vinh Nguyen wrote:
>> hi all,
>> in a loop, i normally output the iteration number every 10 or 100 to
>> know my progress.  however, when doing parallel computing using
>> snow/snowfall, putting the print() or cat() statement into the wrapper
>> function does not output into the main R console.  does anyone know
>> how one would be able to output the iteration (argument into the
>> wrapper function from sfLapply) into the main console?
> Try using message() instead of print() or cat()
> Regards,
>   - Brian
> --
> Brian G. Peterson
> http://braverock.com/brian/
> Ph: 773-459-4973
> IM: bgpbraverock

More information about the R-sig-hpc mailing list