0
$\begingroup$

This question already has an answer here:

Is it possible to print with a carriage return but not a new line? I'd like to keep track of the progress of a long calculation without filling the screen with prints.

$\endgroup$

marked as duplicate by Szabolcs, m_goldberg, bobthechemist, gpap, Michael E2 May 20 '14 at 15:18

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 3
    $\begingroup$ I recommend you use Monitor instead. $\endgroup$ – Szabolcs May 20 '14 at 13:50
  • $\begingroup$ Or if you want use PrintTemporary $\endgroup$ – molekyla777 May 20 '14 at 13:51
  • $\begingroup$ @molekyla777 PrintTemporary will still fill up the screen though, even if the cells are removed when the calculation is done. $\endgroup$ – Szabolcs May 20 '14 at 13:52
0
$\begingroup$

Simplest for me is to use a ProgressIndicator in the interactive notebook: ProgressIndicator[Dynamic[VariableForMapCurrentPosition], {1, LastMapIndex}]

Then have your Map function update 'VariableForMapCurrentPosition' . Two other comments:

  1. As @Szabolcs wrote above, there is more information in previous similar questions.
  2. This doesn't work well with Parallel. You can simply SetShared your position variable, but at least in my case it slows things down -- more than double the time. This post has more on the topic: Monitor doesn't work with ParallelTable
$\endgroup$

Not the answer you're looking for? Browse other questions tagged or ask your own question.