dnbinom(2,0,0.01) ---> 0 pnbinom(2,0,0.01) ---> NaN The former is ok with size==0, the latter not.

There's no actual inconsistency here: pnbinom(2,0,x) == sum(dnbinom(0:2,0,x)) and dnbinom(0,0,x) is NaN. However, it is not obvious to me that we can't just define neg.bin(0,x) as a one-point distribution at zero.

(In reply to comment #1) > There's no actual inconsistency here: > > pnbinom(2,0,x) == sum(dnbinom(0:2,0,x)) and dnbinom(0,0,x) is NaN. > > However, it is not obvious to me that we can't just define neg.bin(0,x) as a > one-point distribution at zero. Would seem natural to me, and consistent with our long effort of defining border line cases by their limit, notably if the limit is unique, i.e. a true mathematical 'limes'. Martin

This was never actually a bug, but the corner case size==0 is now implemented as a one-point distribution at zero. (R-devel for now).