RANDNF Generate Noncentral F-Distribution Random Variable

Section: Random Number Generation

Usage

Generates a vector of non-central F-distributed random variables with the specified parameters. The general syntax for its use is
   y = randnf(n,m,c)

where n is the number of degrees of freedom in the numerator, and m is the number of degrees of freedom in the denominator. The vector c determines the non-centrality shift of the numerator.

Function Internals

A non-central F-distributed random variable is the ratio of a non-central chi-square random variable and a central chi-square random variable, i.e.,

Example

Here we use the randf to generate some non-central F-distributed random variables:
--> randnf(5*ones(1,9),7,1.34)
ans = 
  <float>  - size: [1 9]
 
Columns 1 to 6
 2.01069760  0.18898647  0.74676013  2.37594628  8.25529575  1.80473185  
 
Columns 7 to 9
 0.22219571  2.26800203  1.96904421