For the sake of demonstration in a class I wanted to use the line:

Histogram[Accumulate[RandomReal[{-1, 1}, 100000]], {1}, "Probability"]

to get a probability-like distribution of the random walk process. This worked for me on Mma7, 8, and 9 returning a reasonable probability-like histogram. As soon as I do it now (Mma 10.0.2, Win7) I get for several times the desired histogram. However, after several (about 10) trials I suddenly see the word "Histogram" appearing in red color, and the whole thing stops working, with a message that Histogram is obsolete. So, (i) what happened? and (ii) Could I repair it?

  • $\begingroup$ Hmmm, no problems on a MacBook with Mathematica 10.0.2, code seems to work as it should... $\endgroup$ – mgamer Mar 1 '15 at 20:05
  • $\begingroup$ Same on Mathematica 10.0.0 Windows 8, no errors. Can you reproduce it just by running only that input line a couple of times in a fresh kernel? $\endgroup$ – 2012rcampion Mar 1 '15 at 20:24
  • $\begingroup$ Couldn't reproduce it with Mma 10.0.2 and Win7. $\endgroup$ – Karsten 7. Mar 1 '15 at 23:55
  • 2
    $\begingroup$ I'm curious whether you can still reproduce this Alexei? I can get an error out of your command (MMA 10.2, Linux) but not after 10 trials, after a hundred or more, and my error is different as well. The error message is here $\endgroup$ – Jason B. Oct 14 '15 at 11:57
  • $\begingroup$ @Jason B I tried with Mma10.2 several possibilities, such as plain line given above, Table[...,{200}] and Do[...,{i,200}], where inside the operators there always was the above Histogram statement. No problem now. At least I did not notice with 200 repetitions. $\endgroup$ – Alexei Boulbitch Oct 19 '15 at 7:45

For Mathematica there is no problem:

enter image description here


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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