2

I'm trying to check if a vector of data is well-fitted to the negative binomial distribution, using PearsonChiSquareTest[] function. The problem is that my data are not equally depolyed, so I'd like to choose the intervals /nodes to the Chi Square test manually. Does anyone know how could I do it using any options in Mathematica's functions? Thanks.

  • You might check this out http://mathematica.stackexchange.com/a/5590/43 – Andy Ross Feb 07 '17 at 03:05
  • Basically your only option is to create your own version where you compute expected and observed frequencies. – Andy Ross Feb 07 '17 at 03:07
  • 1
    I'm not sure what you mean by "my data are not equally deployed" or why you should be concerned about that. The PearsonChiSquareTest selects bins based on the estimated values of the parameters such that the probabilities are approximately equal given the supplied distribution. The observed counts can be whatever they are and don't have to be evenly distributed in the bins. The general rule is to have the expected counts no less than 5 and not on the observed counts which can be any non-negative integer. – JimB Feb 07 '17 at 06:10
  • @AndyRoss thanks a lot! I've read that post before and now I did what sould be done. – Sliwka Wegierka Feb 07 '17 at 15:53
  • @JimBaldwin I mean the data were not equally distributed, so I wanted to create manually an artificial division of my data to some subsets to obtain similar amounts of the observations in each set. But anyway thanks for the answer. – Sliwka Wegierka Feb 07 '17 at 17:09
  • 1
    But when the documentation states "The bins are chosen to have equal probability in [the chosen distribution]" that's about the expected counts and not at all about the observed data. – JimB Feb 07 '17 at 19:52

0 Answers0