I defined a security bound for a random walk (cube with 15 length) and I have this code to obtain a sample of the random times at which the random walk crosses the boundary for the first time:
w = Do[i = 0; NestWhile[(i++; # + RandomReal[{-1, 1}, 3]) &, {0, 0, 0}, Norm[#] < 15 &];
Sow[i], {1000}] // Reap
(code taken from Sample of the random times at which the random walk crosses the boundary)
And I constructed a histogram with w:

And now I want to know the distribution of this data. I thought that it was a gamma because of the histogram, but I ran some tests in Excel and I concluded that it isn't, but I would like to confirm that with Mathematica. Is that possible?
And when I do this:
\[ScriptCapitalH] = DistributionFitTest[w[[2, 1]], Automatic, "HypothesisTestData"];
\[ScriptCapitalH]["FittedDistribution"]
I have for output: NormalDistribution[233.588, 150.231], but skewness[w] = 1.83 (if it was normally distributed, it should be approximately zero).
Would like some help please :)





DistributionFitTestto determine whether or not my data fit a gamma distribution?"? If so, then mma.se may be more appropriate than math. – bobthechemist Mar 25 '14 at 13:56Automaticas the second argument does at all what you think. It seems to just assume a normal dist and theAutomaticargument specifies the test type. (Can anyone cook up an example whereAutomaticreturns anything other thanNormalDistribution) ? – george2079 Mar 25 '14 at 15:55DistributionFitTestdefaults to a test for normality. The fitted distribution is NOT the best fitting distribution. It is the best fitting distribution in the family you are testing. When setting the distribution family toAutomaticyou are using the normal family of distributions. – Andy Ross Mar 25 '14 at 18:32FindDistribution[]returns a number of useful candidates:FindDistribution[w[[-1, 1]], 4, All, PerformanceGoal -> "Quality"]– J. M.'s missing motivation Jun 28 '16 at 12:44SmoothHistogramorSmoothKernelDistribution? (And even if the distribution is approximately a gamma for all practical purposes, with a large enough sample size you'll be guaranteed to reject that distribution with any of the standard tests.) – JimB Jun 28 '16 at 15:51