Talk:Negative binomial distribution

message: The method of moments expression is given as p=1-E[X]/V[X], even though 1-E[X]/V[X] clearly evaluates to 1-p if you use the expressions for mean and variance given just above. It seems to me that there's some confusion between p and 1-p. I'm not sure if any similar mixups were made anywhere else in this article, might be worth checking.  — Preceding unsigned comment added by Freedmanari (talk • contribs) 00:17, 13 November 2022 (UTC)
replies: text: I also think that's an error 8.33.1.254 (talk) 17:03, 24 April 2023 (UTC)
replies: text: I agree that there is an error on the method of moments. With this parametrization, it should be simply E[X]/V[X]. 216.164.128.208 (talk) 19:33, 6 October 2023 (UTC)
thread_title: Error in Method of Moments?

message: The variance should be rq/p^2, but is instead listed as rp/q^2, with q=1-p. Is this true for some specific convention? I would expect not. The simple proof for the variance is that each successive geometric random variable of r such variables has the same parameters, so the variance of their sums is the sum of their variances, and as such is r(q/p^2)=rq/p^2. Is this not correct?  — Preceding unsigned comment added by Bargrum (talk • contribs) 00:11, 13 October 2022 (UTC)
thread_title: Error in variance?

message: There isn't yet an article on negative binomial regression in Wikipedia: maybe I'll write one if I get the time. This application of the distribution uses a reparameterization in terms of the mean and dispersion, so I have added a bullet point to clarify what this form is, and the various terms used, with some additional references. I moved Joe Hilbe's book into the references (updating to the second edition), and so deleted the section on additional reading Peterwlane (talk) 06:30, 30 May 2013 (UTC)
thread_title: Negative binomial regression

message: Would not it be a good idea to discuss also the beta negative binomial mixture (see among others Wang, 2011)?
Reference
Wang, Z. (2011). One Mixed Negative Binomial Distribution with Application. Journal of Statistical Planning and Inference, 141, 1153-1160.  — Preceding unsigned comment added by Ad van der Ven (talk • contribs) 10:34, 17 August 2011 (UTC)
thread_title: Beta negative binomial mixture

message: The formula in the section "Sampling and point estimation of p" seems to give the probability of failure, which is not the definition we're using.  For example, if you observe k=0, you saw no successes and k failures, so the probability of success (p) should be low.  But the formula gives p=1.  Should it be changed to k / (r + k) ?  Martin (talk) 15:03, 28 November 2010 (UTC)
thread_title: Wrong p in Sampling and point estimation of p?

message: I can barely read any German, yet the article here made more sense than this one...74.59.244.25 (talk) 03:26, 18 February 2008 (UTC)
replies: text: I'm just noticing this comment now.  I'll look at the German version. Michael Hardy (talk) 17:48, 14 April 2010 (UTC)

text: The German version also has a different form for the CDF, even though it seems to give the same definition of p (as the probability of success). I believe that the German version of the CDF is accurate. 104.129.196.214 (talk) 14:49, 8 October 2018 (UTC)
thread_title: German version is better

message: This article needs a proper introduction, that can help a layman understand what the term means, what it entails when used in text or conversation. Currently, this is not feasible, you'd have to scroll down a long ways and start reading the examples to even begin to understand; if you had no previous knowledge of mathematics or statistics at all. I'm putting this at the top, as I think it's more vital issue than any concerning the mathemathical/statistical content of the page. Starting with 
In probability and statistics the negative binomial distribution is a discrete probability distribution. 
Does not explain what Negative Binomial Distribution is - what separates it from other discrete probability distributions. I personally think this should be attempted as highest priority, obviously I'm not able to do it (or I wouldn't be writing here, eh). Assuming anyone (not to mentione everyone) is able to understand mathematical formulas that incorporate greek letters is IMHO pedagogically unsound  --Asherett 12:17, 13 September 2007 (UTC)
replies: text:  Well, obviously the statement that "In probability and statistics the negative binomial distribution is a discrete probability distribution" does not way WHICH discrete probability distribution it is---that comes later in the article.  As for making it clear to someone who knows NOTHING AT ALL about mathematics or statistics: that may not be so easy.  Perhaps making it clear to a broader audience can be done, with some effort, though. Michael Hardy 19:15, 13 September 2007 (UTC)
thread_title: request for introduction

message: I have reverted the most recent edit to negative binomial distribution for the following reason.  
* Sometimes one defines the negative binomial distribution to be the distribution of the number of failures before the rth success.  In that case, the statement that the expected value is r(1 − p)/p is correct.
*But sometimes, and in particular in the present article, one defines it to be the distribution of the number of trials needed to get r successes.  In that case, the statement is wrong.
If you're going to edit one part of the article to be consistent with the former definition, you need to be consistent and change the definition. Michael Hardy 17:40, 7 Jul 2004 (UTC)
thread_title: reversion

message: shouldn't there be a sentence or two saying why this is name negative binomial and what it has anything to do with binomial, especially for layman.  —Preceding unsigned comment added by 164.67.59.174 (talk) 19:17, 2 September 2009 (UTC)
thread_title: etymology

message: If Xr is the number of trials needed to get r successes, and Ys is the number of successes in s trials, then
:\operatorname{Pr}(X_r \leq s)=\operatorname{Pr}(Y_s \geq r).
The article went from there to say the following:
::Every question about probabilities of negative binomial variables can be translated into an equivalent one about binomial variables.
I removed it.  I tentatively propose this as a counterexample: Suppose Wr is the number of failures before the r successes have been achieved.  Then Wr has a negative binomial distribution according to the second convention in this article, and it is clear that this distribution is just the negative binomial distribution according to the first convention, translated r units to the left.  This probability distribution is infinitely divisible, a fact now explained in the article.  That means that for any positive integer m, no matter how big, there is some probability distribution F such that if U1, ..., Um are random variables distributed according to F, then U1 + ... + Um has the same distribution that Wr has.
So how can the question of whether the negative binomial distribution is infinitely divisible be "translated into an equivalent one about binomial variables"? Michael Hardy 01:43, 27 Aug 2004 (UTC)
replies: text: Removing the bit about "every question" seems OK to me; the important point is the relation between binomial and negative binomial probabilities. But Mike, it wasn't put in there for the purpose of annoying you. You might consider using the edit summary to say something about the edit rather than your state of mind -- how about rm questionable claim about "every question" instead of I am removing a statement that has long irritated me. Wile E. Heresiarch 15:23, 6 Nov 2004 (UTC)
thread_title: Equivalence?

message: Trying to be bold, I've just committed several major changes.  I found the previous version somewhat confusing, since it talked about three slightly different but closely related "conventions" for the negative binomial, and it never became fully clear to me which convention was in use at which point in the subsequent discussion.  I've replaced the definition with what I consider to be the most natural version (the previous convention #3).  The reasons that definition is "natural" is that it arises naturally as the Gamma-Poisson mixture, converges-in-distribution to the Poisson, etc.  The shifted negative binomial (previous convention #1) can still be derived (see the worked example of the candy pusher).  Now we have a single, consistent (hopefully!) definition of the negative binomial instead of three similar-yet-different conventions. I'm painfully aware that all of the previous three conventions are in use and sometimes referred to as the negative binomial; but then again, that doesn't even begin to exhaust the variations on this distribution that can be found in the wild, so why not pick one reasonble definition and stick to that here? --MarkSweep 12:04, 5 Nov 2004 (UTC)
replies: text: Well, if we were writing a textbook, we would certainly want to pick one defn and stick to it. However, we're here to document stuff as it is used by others. If there are multiple defns in common use, I don't see that we have the option to pick and choose. Sometimes multiple defns can be collapsed by saying "#2 is a special case of #1 with A always a blurfle" and then describing only #1. I don't know if that's feasible here. Regards & happy editing, Wile E. Heresiarch 15:09, 6 Nov 2004 (UTC)
replies: text: Yes, that was basically the case here.  The previous "convention #2" was the Pascal distribution, which is a special case of the general negative binomial (previous "convention #3").  This didn't become fully clear in the previous revision, where the discussion of the Pascal distribution seemed more like an afterthought.  The previous "convention #1" appeared to be simply a Pascal distribution shifted by a fixed amount.  There is still a discussion of that in the worked example, but that could arguably be moved to the front and made more explicit. --MarkSweep 23:25, 6 Nov 2004 (UTC)

text: Hi, just found this page and I don't like that the starting point is the more general formula that has r being a strictly positive real. I think that 99% of the time somebody is interested in this distribution, r is going to be an integer. Which isn't to say that we should purge this more complete definition, just that there is a lot to be said for following the way the present article on the Binomial distribution is written (since this is closely related) and because that one is a heck of a lot clearer. I would suggest using one variable where r is an integer and a seperate variable where it is a real (to keep them straight). Along the same lines, I also think that starting talking about Bernoulli trials so far down the page is not a good idea--I'd like to see it up top. Is this what you two are talking about? Oh, wait, those dates are 2004! oh well, I'll still wait to see if anyone cares b/c this is a big edit. --O18 07:13, 9 November 2005 (UTC)

text: I support the previous comment. I am a graduating maths/computer science student, but the first definition was absolutely non-intuitive for me and only the "Occurrence" section made it clear. I doubt whether the generalization is more important than the fact that this distribution is derived from the Pascal distribution. —The preceding unsigned comment was added by 85.206.197.19 (talk) 20:10, 4 May 2007 (UTC)
thread_title: Major reorganization

message: Is it possible to get some plots of what this looks like?  I got sent here from the mosquito page, and anyone reading that probably doesn't want to wade through many lines of math, just see a picture of what it means.  --zandperl 04:10, 30 August 2005 (UTC)
replies: text: .  // stpasha »  23:06, 4 February 2011 (UTC)
thread_title:  Plots? 

message: should be (1-p)r/p, surely
UM According to 'A First Course in Probability' by Sheldon Ross, the mean is r/p
Both are correct. The only difference is in the choice of random variable, in case if you choose X as number of trials for rth success its mean will be r/p, but if Y denote the number of failures for rth success then mean should be rq/p. If you look closely then X and Y are related as follows X=Y+r then using linearity of expectation E(X)=E(Y)+r= rq/p +r =r/p.  — Preceding unsigned comment added by 103.37.200.103 (talk) 05:55, 7 June 2018 (UTC)
replies: text: Wrong.  Look, how many times do so many of us have to keep repeating this?  Sheldon Ross's book CORRECTLY gives the mean of what Sheldon Ross's book calls the negative binomial distribution.  But there are (as this article explains) at least two conventions concerning WHICH distribution should be called that.  Sheesh. Michael Hardy 21:42, 29 November 2006 (UTC)

text: The mean and variance are incorrect as parametrized. Consider the case where r = 1. Then we have the geometric distribution with parameter 1-p. This has mean p/(1-p). Stats-reader121 (talk) 05:20, 10 October 2022 (UTC)

text: f(k) = {k+r-1 \choose r-1} (1-p)^r p^k 
  
then the mean is r*p/(1-p), and the variance r*p/(1-p)^2. Gogol-Döring (talk) 09:44, 21 July 2010 (UTC)
thread_title:  the mean is wrong 

message: The numerator should be pe^t instead of p. The following link can support this
http://www.math.tntech.edu/ISR/Introduction_to_Probability/Discrete_Distributions/thispage/newnode10.html 
The bottom of that page gives the mgf of negative binomial distribution. I verified it. —Preceding unsigned comment added by 136.142.163.158 (talk • contribs) 
:WRONG!!!  This article has it right, and so does the web page you cited.  They're talking about TWO DIFFERENT DISTRIBUTIONS.  You did not read carefully.  The negative binomial distribution dealt with in this article is supported on the set
::{ 0, 1, 2, 3, ... }
:whereas the one on the web page you cite is supported on the set
::{ r, r + 1, r + 2, .... }
:Both articles are clear about this.  You need to read more carefully. Michael Hardy 19:55, 13 September 2006 (UTC)
replies: text: Both articles may be mathematically correct, but the using the number of successes as the RV, the number of failures as the goal (one parameter), and the probability of success as the other parameter is to me less intuitive than using the number of failures as the RV, number of successes as the goal parameter, and the probability of success as the other parameter. The introduction to the example of selling candy using the article's current convention seems unnatural and forced. There is much more than being mathematically correct. Lovibond (talk) 16:45, 11 October 2015 (UTC)

text: Hi Vapniks, thank you for your input on the mgf. I just found the domain of the mgf seems still inaccurate: it probably should be "t<-log(1-p)". However, personally I do not know how to edit it on Wiki... Lcat0718 (talk) 10:08, 14 April 2023 (UTC)
thread_title:  the mgf is wrong 

message: Is it the convention among probability literature to represent the negative binomial with the gamma function?  In Sheldon Ross's introductory text, the distribution is introduced without it (although that is an alternative representation of the distribution).  I am not objecting but as a beginner am curious why this is how it is represented.  --reddaly
I think either adding this way of writing it: \binom{n-1}{r-1}p^{r}(1-p)^{n-r}, or specifying that \Gamma(x + 1) = x! would be beneficial. some people start running when they see the gamma function
:Good idea. It would be easier on the eyes for those who haven't yet discovered how to love the Γ function. Aastrup 22:24, 18 July 2007 (UTC)
thread_title: Use of gamma function for a discrete distribution

message: The classic derivation of the mean of the NBD should be on this page, as it is on the binomial distribution page. 
--Vince |Talk| 04:44, 12 May 2007 (UTC)
replies: text: I agree. Aastrup 22:24, 18 July 2007 (UTC)
thread_title: Expected Value derivation

message: This article lacks Maximum Likelihood, and especially Anscombe's Conjecture (which has been proven). Aastrup 22:24, 18 July 2007 (UTC)
thread_title: MLE

message: I recently added a note about how the Poisson distribution with a dispersion parameter is more general than the negative binomial distribution and would make more sense when one is simply looking for a Poisson distribution with a dispersion parameter.  I think it's important to realize that the Poisson distribution with a dispersion parameter described by M&N is more general in that the variance has positive support instead of the more limited greater support than the mean. There certainly are situation where the negative binomial distribution makes sense, but if one is just looking for a Poisson with a dispersion parameter, why beat around the bush with this other distribution and not just go for the real thing?  O18 (talk) 17:38, 26 January 2008 (UTC)
replies: text: There is no such thing as "overdispersed Poisson", because if it is overdispersed, then it is not Poisson. If "the Poisson distribution with a dispersion parameter described by M&N" is important, then go ahead and describe it in some other article, perhaps in a new article. This article is about the negative binomial distribution only. The (positive) binomial distributions have variance < mean, and the Poisson distribution has variance = mean, and the negative binomial distribution has variance > mean. Bo Jacoby (talk) 22:36, 26 January 2008 (UTC)
thread_title:  overdispersed Poisson 

message: Among several objections I have to the edits done on April 1st by 128.103.233.11, is this: the rest of the article is about the distribution of the number of failures before the rth success, not about the one that counts the number of trials up to and including the rth success.  Thus, in the experiment that that user described, the distribution should have started at 0, not at 2.  This matters because (1) we want to include the case where r is not an integer, because (2) we want to be able to see the infinite divisibility of this distribution. Michael Hardy (talk) 16:23, 4 April 2009 (UTC)
thread_title:  First paragraph 

message: Are we reading the same The Little Match Girl article? The one that is linked is about a girl who dies on a cold night after being too afraid to return home for fear of being punished, and instead dies in the cold. I really don't see the link between the Andersen story and this article, nor why it is a "classic example" of a negative binomial distribution. Considering what is in the linked article, I see no benefit (and a great deal of confusion) by putting that link there. The story is similar to the example of pat, but totally non mathematical, and adds no information about the neg. bin. dist. Just to make things clear, I am not the IP earlier, and I don't think the link should be there User A1 (talk) 02:57, 25 July 2009 (UTC)
replies: text: In the setup of TLMG, Pat must empty her box of matches or face child abuse. In Dr. Evans' example, Pat must empty her box of candy bars or face child abuse. What is the probability that Pat freezes to death? --Damian Yerrick (talk | stalk) 13:10, 25 July 2009 (UTC)

text: So, in explaining about Fisher's exact test, do you think it would be inappropriate to add a link to the problem of adding the milk while the tea is still steeping (were such an article to exist)? In one sense it is not apropos, in another, it is just part of the canon regardless of how interesting it looks when you don't know the history. O18 (talk) 20:12, 25 July 2009 (UTC)

text: I think that the link firstly is far to tenuous, both myself and an IP have no idea what you are on about w.r.t. the link. Secondly, I would remind you of WP:EGG (no easter egg links). Finally, should we then link integer to Hansel and gretel, temperature, porridge and bed to little red riding hood?  Follicle_(anatomy) to Rapunzel ? I consider the links no more bizzare than this.User A1 (talk) 01:45, 26 July 2009 (UTC)
replies: text: Just to be clear, I believe Damian is being sarcastic? User A1 (talk) 01:47, 26 July 2009 (UTC)

text: Sorry, still going: in explaining about Fisher's exact test, do you think it would be inappropriate to add a link to the problem of adding the milk while the tea is still steeping. Sure that's fine, as it is a good example of the applicability of the mathematics, but I wouldn't then link that to waltzing matilda, on the pretext that the swagman steeps his tea. User A1 (talk) 01:49, 26 July 2009 (UTC)
replies: text: After using google for a while, it appears that the little match girl, negative binomial link was only on website that use the text as it used to appear in this article. I don't understand why you couldn't see why the link was related, but given that it is 2 to 1, and the 1 doesn't really care, I say lets just ax it and be done. O18 (talk) 05:30, 26 July 2009 (UTC)
thread_title:  Little match girl 

message: The recent edits by user:24.127.43.26 and by user:Phantomofthesea make me wonder if we need to dumb this down again to rid ourselves of irresponsible editors who edit without paying attention to what they're reading or what they're writing. Michael Hardy (talk) 02:52, 19 February 2010 (UTC)
replies: text: Maybe we should reject the “success/failure” terminology altogether, and instead use something more neutral, like “0/1”. That way whenever a person reads this page he/she would have to stop for 3 seconds and think how our 0/1 maps to his/her textbook’s success/failure.  // stpasha »  20:51, 15 April 2010 (UTC)
thread_title:  More dumbing down needed? 

message: I don't want to mess with the entry, but according to Casella & Berger, the pmf listed here is incorrect. The p and (1-p) are switched. It should be (p^r)(1-p)^k. I haven't looked through to see how that mistake affects the rest of the article, if at all, so I'll leave it to someone with more knowledge of this article than me to correct. —Preceding unsigned comment added by 128.186.4.160 (talk • contribs) 
:: Sigh............. not this comment again.  The article says:
:::: Different texts adopt slightly different definitions for the negative binomial distribution.
:: OK?  You need to read what it says!. Michael Hardy (talk) 21:25, 13 April 2010 (UTC)
replies: text: I don't see where this decision was discussed above. In the first instance that I see of such a discussion Michael Hardy is saying it has happened before, so I guess there must be an unlinked archive? 018 (talk) 02:58, 14 April 2010 (UTC)

text: Sorry, I've now looked at this talk page and see that it looks to me like MH pointed out that any change would require the entire page be changed in the section titled, " reversion". Since then in the section, "Trials up to rth success" Formivore correctly predicts endless waves of people correcting it because of the more intuitive interpretation of the alternative specification. There has also been a more lengthy discussion in the section titled "Major Changes" where Formivore tries to update the article and describes it as being in disarray and confusing. Formivore appears to have given up. In the end MH likes that one can make a (somehow useful?) change of support for one of the parameters for the less intuitive parameterization. 018 (talk) 04:47, 14 April 2010 (UTC)
replies: text: To focus my ramble into a question, what is the value of being able to treat r as real and not just integer valued? Why do we care? Also, even if we do want this, might it make more sense to give that formulation a separate section that starts by reparameterizing, showing the new cdf/pdf and then explaining why it is useful. 018 (talk) 17:02, 14 April 2010 (UTC)
replies: text: Another reason you might want r to be real is so that the negative binomial becomes an overdispersed generalization of the Poisson distribution. That is the only capacity in which I use the negative binomial distribution in my own work. That having been said I agree that the suggestion to have the more general parameterization in a separate section makes sense. 69.143.122.185 (talk) 16:12, 23 February 2023 (UTC)

text: Okay, so (1) Why is there no mention of "Levy process", and (2) why does this trump the overall understandability of the article? Would you agree that this parameterization could be moved it its own section? 018 (talk) 18:09, 14 April 2010 (UTC)
thread_title: a question

message: In the summary on the right hand side we have:
r - is the number of failures
pmf: c \times (1-p)^r p^k
which makes sense.
Then in the definition section we have, success is p, failure is (1-p)  but then the pmf function is given as
c \times (1-p)^k p^r
which is the wrong way round -  this gives the probability of k failures in r+k trials.  This error continues thoughout the definition section.  However in the related distributions section when the more common version of the pmf is written using \lambda (more commonly \theta in my experiance) we have (1-p)^r p^k, which is as it should be following the textual definitions given previously.  —Preceding unsigned comment added by 193.63.46.63 (talk) 10:24, 4 October 2010 (UTC)
thread_title:  Error in definition section equations. 

message: The outcomes "success" and "failure" are concrete and can be mapped to a set {1,0} by an indicator function. The values "good" and "bad" are subjective values based on social constructions, experiences and personal preferences (concepts that may not even exist in concrete form). The comparison here between "success"/"failure" and good"/"bad" does not make any sense:
"When applied to real-world situations, the words success and failure need not necessarily be associated with outcomes which we see as good or bad." The point of an experiment is *not* to have subjective biases, so why would the experimenter see the outcomes as good or bad? Runestone1 (talk) 00:44, 2 June 2011 (UTC)
replies: text: The quote agrees with you...  — Preceding unsigned comment added by Machi4velli (talk • contribs) 09:43, 1 July 2013 (UTC)
thread_title:  Concrete outcomes vs subjective values 

message: In the "Extension to real-valued r" section, I see a denominator of "x! gamma(x)". Is that right, or should it be "x gamma(x)"?
: It's correct. Note that if x were a positive integer, we would have gamma(x) = (x-1)!, and you'll see that it would reconstruct the binomial coefficient in the integer case Machi4velli (talk) 10:00, 1 July 2013 (UTC)
thread_title:  Correct equation? 

message: The current mode given doesn't seem to match other sources for negative binomial mode. I've checked under the multiple parameterizations and haven't come up with that formula. Can someone else confirm of deny this?  — Preceding unsigned comment added by 108.246.235.64 (talk) 23:40, 19 July 2013 (UTC)
replies: text: The current mode given doesn't seem to match other sources for negative binomial mode. I've checked under the multiple parameterizations and haven't come up with that formula. Can someone else confirm of deny this?  — Preceding unsigned comment added by 108.246.235.64 (talk) 23:49, 19 July 2013 (UTC)
thread_title:  Mode does not appear to be correct 

message: I changed the second sentence of the section "Gamma–Poisson mixture" which had suggested that 
negativebinomial(r,p) ~ poisson(gamma(shape = r, shape = p/(1 − p))).  Instead, it should be the rate parameter that should have that value.  Here's some R code that makes it obvious:
:many = 10000
:r = 15    # trunc(runif(1,2,20))
:p = 0.56  # runif(1)
:x = rnbinom(many,r,p)
:
:# negativebinomial(r,p) ~ poisson(gamma(shape = r, rate = p/(1 − p)))
:lambda = rgamma(many,shape = r, rate = p/(1 − p))
:y = rpois(many,lambda)
:
:# negativebinomial(r,p) ~ poisson(gamma(shape = r, scale = p/(1 − p)))
:lambda = rgamma(many,shape = r, scale = p/(1 − p))
:z = rpois(many,lambda)
:
:plot(sort(x),1:many/many, xlim=range(c(x,y)),ylim=c(0,1),col='green', lwd=3, type='l')
:lines(sort(y),1:many/many, col='blue')
:lines(sort(z),1:many/many, col='red')
Scwarebang (talk) 00:24, 12 October 2013 (UTC)
thread_title:  Gamma-Poisson mixture parameter confused 

message: CDF: 1-I_p(k+1,\,r), the regularized incomplete beta function.
According to the regularized incomplete beta function  I_x(a,b) = \sum_{j=a}^\infty \binom{a+b-1}{j} x^j (1-x)^{a+b-1-j}.
So, CDF=1-\sum_{j=k+1}^\infty \binom{k+r}{j} p^j (1-p)^{k+r-j}. But we know that CDF=1-\sum_{j=k+1}^\infty \binom{j+r}{j} p^j (1-p)^{r}.
: I agree that the CDF is wrong. Based on the way p is defined (as the probability of success), I would have expected 1-I_{1-p}(k+1,\,r) or I_p(r,\,k+1). I've been going in circles for a while trying to figure out why values calculated using this (incorrectly) presented CDF don't match R's pnbinom function. Fwiw, the German version of this page presents the CDF as 1-I_{1-p}(k+1,\,r), which matches numerical calculations.  — Preceding unsigned comment added by 104.129.196.214 (talk) 14:55, 8 October 2018 (UTC)
replies: text: Yes, the CDF is wrong. Based on the discussion above, and multiple references. I fixed the CDF in the article body, but I can not figure out how to fix the CDF in the article's table, so it is still wrong in the table. If anyone can fix it in the table that would be appreciated. 69.143.122.185 (talk) 16:14, 23 February 2023 (UTC)
thread_title:  Isn't the CDF wrong? 

message: Doesn't the MLE section use the wrong pmf (where r is the number of successes instead of failures)? This is inconsistent with the rest of the article.  — Preceding unsigned comment added by Nicole.wp (talk • contribs) 23:35, 27 May 2014 (UTC)
thread_title:  MLE section uses wrong pmf? 

message: The case with r real contradicts the initial definition "The number of successes before r failures in independent Bernoulli trials". It should be made clear at the outset that this case is a special case.
The reason for putting this case first seems to have been that it's the most common in practice. I doubt this, although it might, perhaps, be the most common in elementary texts (and is all that the Wolfram Math World article discusses).
The real case occurs often when the assumptions for the Poisson distribution are not quite met.
For example, fatal road accidents tend to follow the Poisson distribution, while deaths do not because more than one may occur in a single accident. We get the negative binomial if the number of deaths per accident follows a logarithmic series distribution.
Similarly, people can have different rates for non-fatal accidents, so that repeated accidents to the same person are not Poisson distributed.
I remember the second case from my first statistics course in my first year at university (1964/65). Greenwood and Yule (1920) studied accidents to women manufacturing high explosive shells in World War I. Letting the Poisson parameters for individual workers (representing accident proneness) be gamma distributed gives the negative binomial.
(In our course we started with the negative binomial and an accident proneness variable with an arbitrary distribution. This then gives rise to an integral equation for this distribution which the gamma fitted. High school calculus was a prerequisite for B.Sc. and the course discussed the beta and gamma distributions, but we would not have been able to solve the integral equation except by trying all the continuous distributions we knew.)
I suggest starting with a description such as "the negative binomial is a distribution on the integers 0, 1, 2, 3, ... with two parameters often denoted by p and r where p is between 0 and 1 and r is positive."Then continue with "The special case when r is an integer is known as the Pascal distribution and represents the number of successes in independent Bernoulli trials before obtaining r failures." I also think the different definitions in the Pascal case should be mentioned here and not relegated to a side bar.
Continue "The more general case (also known as the Polya distribution) occurs in at least two ways." Then list those ways as I described above.
We should also mention in the article (but not in the introduction) that alternative parametrizations for the Polya case are often more useful, for example the mean = pr/(1-p) = \mu and r or odds ratio = p/(1-p) = \theta and r.
TerryM--re (talk) 00:30, 6 October 2014 (UTC)
thread_title:  Inconsistent introduction 

message: The negative binomial distribution as defined in this article represents the number of successes (k) before r failures. The fisher information is correct for the formulation representing the number of failures (k) before r successes. See the following 
WolframAlpha calculation:
Basically, p and (1-p) need to be switched.
:I agree. I have calculated it myself but I don't know how to change the original.
:Note that this only applies to known r (which usually means that r is an integer). When both r and p are both unknown Fisher's information becomes a matrix which doesn't have a closed form.
:TerryM--re (talk) 21:01, 3 December 2014 (UTC)
thread_title:  Incorrect Fisher information for the convention used in this article 

message: The article head includes the statement, "There is a convention among engineers, climatologists, and others to reserve “negative binomial” in a strict sense or “Pascal” for the case of an integer-valued stopping-time parameter r, and use “Polya” for the real-valued case."  I'm wondering whether people think it would useful to note that this convention is not followed in bioinformatics.  Specifically, the negative binomial distribution plays a central role in interpreting the counts of Next Generation Sequencing reads as over-dispersed Poisson variates.  See the deseq package homepage http://bioconductor.org/packages/release/bioc/html/DESeq.html .  Note that this is among the top 5% of downloads in bioconductor, bioconductor being something of an industry standard distribution of analysis packages. (here's a citation for that claim http://www.nature.com/nmeth/journal/v12/n2/abs/nmeth.3252.html
I might edit the sentence as follows: "There is a convention in fields such as engineering and climatology (notably excluding bioinformatics) to reserve “negative binomial” in a strict sense or “Pascal” for the case of an integer-valued stopping-time parameter r, and use “Polya” for the real-valued case." or perhaps "There is a convention among engineers, climatologists, and others to reserve “negative binomial” in a strict sense or “Pascal” for the case of an integer-valued stopping-time parameter r, and use “Polya” for the real-valued case (notably, this convention is not observed in bioinformatcs)."
So my question is, is the loss in clarity due to inserting a parenthetical element like that worth the added information?  Having written this, I'm not so sure, because it seems like if you know enough to understand (or even wonder about) the relevance of the NBD to bioinformatics, the naming convention issue won't confuse you.  And besides, is bioinformatics so important that the exception is worth putting in the head of the article?  I mean, it's my field, so it's hard for me to judge its notability. Flies 1 (talk) 00:04, 31 January 2016 (UTC)
thread_title:  Polya naming convention - bioinformatics 

message: I realize the median of this distribution is hard to find (papers exist on the bounds), but that fact should at least be mentioned on the page Barry.carter (talk) 12:26, 24 December 2016 (UTC)
thread_title:  Median is hard to find 

message: Is the gif for the pmf wrong? Because as there is a higher number of successes necessary, the random variable should also increase and thus mean too. It will start looking more normal but also shift right, correct? Plus, when r=40, there is no way that k could be so low. That doesn't make sense to me
SwagmanJ (talk) 16:14, 19 June 2019 (UTC)
thread_title:  Is the gif for the pmf wrong? 

message: Looking at this now, I'm sure that the formula for the mean in the sidebar doesn't agree with the definition of p in the very same sidebar. One seems to use p as probability of success, but the mean seems to use it as the probability of failure. It would be nice if it could be consistent within the same sidebar. 92.23.239.27 (talk) 16:11, 3 April 2020 (UTC)
replies: text: Yeah the use of p,k, and r seem inconsistent. On the sidebar, r is the number of failures and k is the number of successes. Elsewhere, r is the number of successes and k is the number of failures. In pmf definition paragraph, p is the probability of success, but the formula gives Pr(X=k) = ...(1-p)^r..., which is (probability of failure)^(number of success), which is surely wrong. 2607:FEA8:1CE0:D71B:4541:EA2D:A73A:C911 (talk) 21:34, 23 April 2020 (UTC)
replies: text: The pmf in the sidebar is plain wrong. If k is the number of successes the binomial coefficient should be choosing k-1 since the last trial must be a success. But it chooses k instead which is nonsense! Silverhammermba (talk) 05:41, 25 April 2020 (UTC)

text: The mean in the side-bar is indeed incorrect should be (1-p)r/p. How do we fix this? Causing lots of confusion and stealing man-hours from this world.  — Preceding unsigned comment added by Rohitpandey576 (talk • contribs) 06:08, 3 August 2020 (UTC)

text: An error was introduced into the PMF formula on 17-Jun-2020. I have fixed that. I think the more simple ones like mean, PMF etc are correct as defined in the sidebar; and match what was originally put there in 2010. The sidebar has a very strange convention: r (the number which is fixed) is defined as failures, but p is the probability of success. That is why the PMF has a (1-p)^r term (prob of failure ^ number of failures), when most of us are probably used to seeing p^r (prob of success ^ number of successes). Adpete (talk) 05:21, 24 August 2020 (UTC)
thread_title:  Mean does not agree with parameter definitions 

message: In the text the parameter r is described as the following:
[...] before a specified (non-random) number of successes (denoted r) occurs.
However in the infobox to the right the definition is:
r > 0 — number of failures until the experiment is stopped (integer, but the definition can also be extended to reals)
As comparision the German site has the following in the infobox:
r > 0 — Anzahl Erfolge bis zum Abbruch
which means translated number of successes until stop, so the opposite of the English infobox, but in line with the english article.
--130.225.188.33 (talk) 13:28, 11 August 2020 (UTC)
replies: text: I came here to say the same thing! The lead defines r as successes, while the infobox defines r as failures (and even more confusingly, k as successes). r is used for successes at Wolfram Mathworld  and, from a quick google, seems more popular too. It is also used in both textbooks I have on hand (Sheldon Ross, Introduction to Probability Models; Wackerly, Mendenhall and Scheaffer, Mathematical Statistics with Applications). And as the above editor points out, German Wikipedia uses r for successes too. So I think we should change it to r successes and k failures throughout. Adpete (talk) 04:05, 24 August 2020 (UTC)
replies: text: DONE. I have changed the definitions in :Template:Negative binomial distribution to match the article (and most sources). I have not changed any formulae BUT I am pretty sure some of the formulae are wrong. e.g. the mean.  I did not change it because all the Infobox formulas would have to change, and I don't have the time ATM. But I think it should be changed. Note also some formulae have been added to Infobox in recent years; they should all be checked. Adpete (talk) 04:56, 24 August 2020 (UTC)
replies: text:  I can take the Infobox changes on — the only thing is I couldn't find the Infobox when I looked at the article's source. I'm fairly inexperienced with Wikipedia so if somebody could point me in the right direction for where to look it would be much appreciated. --Data Boiiii (talk) 14:58, 11 October 2020 (UTC)
thread_title:  Inconsistency in definition of parameter r 

message: Should be E(X)=r(1-p)/p  — Preceding unsigned comment added by 2001:16B8:469B:1A00:B41D:FED1:BFF3:5A82 (talk) 13:43, 27 September 2020 (UTC)
replies: text: That is because the parametrisation here.  Here the expected number of successes before stopping is an increasing function of the probability of succeeding 17:33, 17 November 2020 (UTC)
thread_title: Mistake in the expression for the mean

message: Some comments want to edit the Infobox.  It can be found at Template:Negative_binomial_distribution but if changed then it needs to be changed in its entirety, including things like CDF and skewness and characteristic function. --2A00:23C7:7B18:9600:895C:FB70:977B:A00A (talk) 00:47, 25 May 2021 (UTC)
thread_title:  Infobox 

message: I believe that the interpretation of negative binomial distribution in the intro is wrong. The probability to have x successes before k failures is measured by Gamma distribution (or x-k successes, to be precise), not negative binomial, cause in neg-binomial the normalisation factor is missing. In Neg-Binomial you divide number of ways to achieve x successes before k failures by the number of ways to have any number of successes and losses in a sequence of exactly (x+k) tosses. 
Instead, what the formulation "probability to get x successes before k losses" implies, is that you divide the number of ways to achieve x successes before k losses by the sum of (ways to get 1 success before k losses + ways to get 2 successes before k losses + ... + ways to get infinity successes before k losses). This last probability is described by gamma-distribution, not negative-binomial. — Preceding unsigned comment added by 94.25.174.77 (talk • contribs) 
:  I'm having trouble understanding what you're saying here. But the gamma distribution is a continuous distribution, and here we're dealing with a discrete distribution. Michael Hardy (talk) 01:33, 11 January 2022 (UTC)
thread_title:  Incorrect interpretation of meaning of negative-binomial distribution in the intro 

message: There are several comments here in the talk page about the selling candy example, and how overwrought it is. Above and beyond the storyline's unsure footing, the reference of only having 30 houses in the neighbourhood begs confusion with the conventional binomial distribution, because it should be the fixed nature of the number of successes (or failures) that should take pride of place in an example of the negative binomial distribution. I got rid of the first mention of this but kept the second.  — Preceding unsigned comment added by Nutria (talk • contribs) 15:41, 1 June 2022 (UTC)
thread_title:  selling candy example, again 

message: This section needs elaboration. 68.134.243.51 (talk) 19:55, 21 August 2022 (UTC)
thread_title:  Length of hospital stay example 

message: Posting this here seeking community approval before editing the sidebar, as requested in the sidebar page.
Given the pmf currently used in the sidebar
 f(k) = \binom{k+r-1}{k}(1-p)^r p^k 
I believe the formula for V[k] shown in the sidebar is incorrect.
The easiest way to see this is by noting:
1. Intuitively, the formula for the mean \big(E[k] = \frac{pr}{1-p}\big) is correct (at least, p belongs in the numerator there). You can convince yourself of this by realizing the pmf is formulated such that k is the number of successes before the r^{th} failure and p is the success probability.
2. A property of the Negative Binomial distribution (mentioned in the article) is that V[k] = E[k] + \frac{1}{r}E[k]^2
So, for fixed r, the variance ought to increase as the expected value increases. For fixed r, the expected value increases with p and so the variance must also increase with p, and the current variance formula cannot be correct.
I am pretty sure the variance of  k  should instead be given by V[k] = \frac{pr}{(1-p)^2}, though I imagine proving this involves frustrating manipulation of binomial coefficients. 
Bernoulli18 (talk) 04:00, 27 September 2022 (UTC)
replies: text: This a symptom of the persistent issue here over the four possible definitions. Whether you think the variance is \frac{pr}{(1-p)^2}  or \frac{(1-p)r}{p^2} depends on whether fixed r is the number of successes or failures (with p being the probability of a success).  Whether you think the mean is \frac{pr}{1-p} or \frac{(1-p)r}{p} or \frac{r}{1-p} or \frac{r}{p} depends on that choice and whether the minimum possible result is 0 or r (so in the latter case measuring attempts as the random variable). It is important that the sidebar is self-consistent, so do not change part without changing the rest, and desirable that it is consistent with the article. --2A00:23C6:148A:9B01:A9DC:D2B8:5DC6:D0A (talk) 12:30, 20 November 2022 (UTC)
thread_title:  Error in the sidebar Variance formula 

message: For about a week, this page had the incorrect formula for P(k;r,m), until I corrected it yesterday. When editing the page to arbitrarily match one definition of p or another, please remember that the mean-shape parametrization should not change, because it does not depend on p. Instead, p is one of the two terms in that parametrization; which one it is reflects a specific convention. Please do not change P(k;r,m) due to issues with the parametrization of p. 2600:6C50:5300:F00:EC7D:7688:2015:DEA5 (talk) 19:41, 18 February 2023 (UTC)
thread_title:  the mean-shape parametrization is non-arbitrary 

message: Please see the template about the formula for the kurtosis. Per Westerlund (LTU) (talk) 06:39, 30 March 2023 (UTC)
thread_title:  Kurtosis 

message: The skewness formula was out of sync with the definitions of r and p, possibly because of previous changes.  The current definitions match those in Wolfram MathWorld, but the formula was \frac{1+p}{\sqrt{p r}} which has p as the probability of failure instead of success (as it is here and in Wolfram MathWorld).  I simply fixed it on the template page (by substituting 1-p for p in the above formula)--I am too busy to first discuss, then get agreement, then fix it.  To be completely sure, note also that the probability mass function is identical with Wolfram MathWorld (up to a different choice for whether to use k or r-1 on the bottom of the choose function).  And to be extra-extra sure, I ran a numerical simulation which checked out with the fixed (Wolfram MathWorld) form and not the one previously here.
Anyway, please think at least as carefully as I have before making any further changes! Ichoran (talk) 03:23, 26 July 2023 (UTC)
thread_title:  Fixed skewness