PRO DisplayRestTime, factor, INITIALIZE = initialize

  COMMON DisplayRestTimeCommon, timeLeft

  IF Keyword_Set( INITIALIZE ) THEN BEGIN
    timeLeft = ETC( 0 )
    RETURN
  ENDIF

  timeLeft = ETC( factor, DELTA = 0.5 )
  IF timeLeft NE -1 THEN BEGIN
    SecHMS, timeLeft, h, m, s
    Print, h, m, s, $
	FORMAT='("Estimated time to completion: ", '+ $
		' 2(I2, ":"), I2 )'

  ENDIF

END
