Skip to content

Non-central distributions

4 messages · Bill Venables, Martin Maechler, (Ted Harding) +1 more

#
Ted Harding says:
[WNV]  The density functions for the t and F distributions are in
fact quite easy and only require hypergeometric functions in addition to
standard things.  These could be useful anyway for all sorts of things.
	As far as I know, percentage points of the non-central distributions
are not much used, but what would be very useful would be to have the
percentage points (with respect to the non-centrality parameter) of the
distribution function G(delta) = 1-P(X^2, n, delta), (i.e. you take the
upper tail area as defining a distribution function in delta.  Such a
distributon has a finite probability at the origin, of course.  These are
the quantities you need, for example, for things like sample size
determination and power calculations.

	Random numbers from the non-central distributions are easy enough to
generate, of course, using the central ones.  Again, I'm not sure just how
much slick versions of them would be useful, though.
[WNV]  Tsk tsk, Ted.  They are there for pf and pchisq, at least.

	Bill Venables.
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
#
Bill> Ted Harding says:
    >> -----Original Message-----
    >> From: 	Ted.Harding at nessie.mcc.ac.uk
    >> Sent:	Friday, October 18, 2002 2:14 AM
    >> To:	Peter Dalgaard BSA
    >> Cc:	r-help at stat.math.ethz.ch
    >> Subject:	Re: [R] Non-central distributions
    >> 
    >> Thanks, Peter! (Must try to give this some thought ...).

    Bill> [WNV] The density functions for the t and F
    Bill> distributions are in fact quite easy and only require
    Bill> hypergeometric functions in addition to standard
    Bill> things.  These could be useful anyway for all sorts of
    Bill> things.  As far as I know, percentage points of the
    Bill> non-central distributions are not much used, but what
    Bill> would be very useful would be to have the percentage
    Bill> points (with respect to the non-centrality parameter)
    Bill> of the distribution function G(delta) = 1-P(X^2, n,
    Bill> delta), (i.e. you take the upper tail area as defining
    Bill> a distribution function in delta.  Such a distributon
    Bill> has a finite probability at the origin, of course.
    Bill> These are the quantities you need, for example, for
    Bill> things like sample size determination and power calculations.

probably an exercise of reading the sections in Johnson et al
(see "HRK" below). I remember having seen quite a few references there.
Contributions are welcome..

    Bill> Random numbers from the non-central distributions are
    Bill> easy enough to generate, of course, using the central
    Bill> ones.  Again, I'm not sure just how much slick
    Bill> versions of them would be useful, though.

In the next major version of R, 1.7.x,
I plan to have finished the code for rchisq(*, ncp = *)
{and possibly for some of  ?chisq(*, df = 0, *) }
thanks to a suggestion from Hans R. Kuensch:

  HRK> I think the help file for the Chisquare distribution should
  HRK> indicate clearly whether df has to be a natural number or can be
  HRK> any positive number. Also I don't understand why rchisq works
  HRK> only in the central case. It should be easy to do the general
  HRK> case by decomposing it as the sum of a central chisquare with df
  HRK> degrees of freedom plus a noncentral chisquare with zero degrees
  HRK> of freedom (which is a Poisson mixture of central chisquares
  HRK> with integer degrees of freedom), see Formula (29.5b-c) in
  HRK> Johnson, Kotz, Balakrishnan (1995).  The noncentral chisquare
  HRK> with arbitary degrees of freedom is of interest for simulating
  HRK> the Cox-Ingersoll-Ross model for interest rates in finance.


    >> Anyway, in this respect R is still ahead of S-Plus, which
    >> doesn't seem to carry ANY non-centrality as standard!
    >> (Except possibly obscurely tucked away in some add-on library).

    Bill> [WNV]  Tsk tsk, Ted.  They are there for pf and pchisq, at least.

     [ but of course, R is still ahead  ;-) ;-) ]

Martin Maechler <maechler at stat.math.ethz.ch>	http://stat.ethz.ch/~maechler/
Seminar fuer Statistik, ETH-Zentrum  LEO C16	Leonhardstr. 27
ETH (Federal Inst. Technology)	8092 Zurich	SWITZERLAND
phone: x-41-1-632-3408		fax: ...-1228			<><
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
#
On 18-Oct-02 Bill.Venables at cmis.csiro.au wrote:
Yes, this is precisely why I was looking for non-central t.
(Your "fiducial" inversion of the distribution function would
of course give confidence limits for delta at the percentiles.)
OOPS! Yes, you are right, now that I look properly. In fact it
is there for pf, pchisq and pbeta. (Having failed with pt, and
adopted a misguided search strategy in S-Plus's on-line Language
Reference -- namely, hoping that "full-text search" for "central"
would hit it -- I concluded that it wasn't there ... ).

But, as Martin Maechler says, R is still ahead on that front!

Best wishes,
Ted.

--------------------------------------------------------------------
E-Mail: (Ted Harding) <Ted.Harding at nessie.mcc.ac.uk>
Fax-to-email: +44 (0)870 167 1972
Date: 18-Oct-02                                       Time: 09:45:52
------------------------------ XFMail ------------------------------
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
#
In message <15791.44578.187614.230488 at gargle.gargle.HOWL> you write:
I haven't followed this entire thread, so I apologize if I'm
completely off the mark, especially since I strongly suspect that
Martin and others would be aware of this information already.

Still, FWIW, probably all of these routines are available, albeit in
Fortran, in Barry W. Brown, James Lovato, and Kathy Russell's cdflib,
which seems to be unencumbered by any license restrictions.  I have
used this library before without any problems, and I'm sure that I
have dynloaded it into Splus, and probably into R as well.  Maybe it
would at least be useful as a reference while you code this up in C?
Should be on statlib.