How can I `print` or `cat` when using parallel

后端 未结 2 1259
萌比男神i
萌比男神i 2020-11-30 00:53

If I call a function using parSapply then print, message or cat statements inside that function don\'t seem to output to

2条回答
  •  一向
    一向 (楼主)
    2020-11-30 01:45

    Using outfile param in makeCluster you can redirect the output to a file and then check that file to see how your program progresses.

    Interestingly on a Linux machine setting it to "" outputs to the console, but that doesn't work for me on a Windows machine. File output works on both.

提交回复
热议问题