RANCAU Function


Returns a random variate from a Cauchy distribution

Category: Random Number

Tip: If you want to change the seed value during execution, you must use the CALL RANCAU routine instead of the RANCAU function.

Syntax

RANCAU ( seed )

Arguments

seed

  • is an integer. If seed 0, the time of day is used to initialize the seed stream.

  • Range: seed < 2 31 -1

  • See: 'Seed Values' on page 257 for more information about seed values

Details

The RANCAU function returns a variate that is generated from a Cauchy distribution with location parameter 0 and scale parameter 1. An acceptance- rejection procedure applied to RANUNI uniform variates is used. If u and v are independent uniform (-1/2, 1/2) variables and u 2 + v 2 1/4, then u / v is a Cauchy variate. A Cauchy variate X with location parameter ALPHA and scale parameter BETA can be generated:

 x=alpha+beta*rancau(seed); 

Comparisons

The CALL RANCAU routine, an alternative to the RANCAU function, gives greater control of the seed and random number streams.

See Also

Call routine:

  • 'CALL RANCAU Routine' on page 368




SAS 9.1 Language Reference Dictionary, Volumes 1, 2 and 3
SAS 9.1 Language Reference Dictionary, Volumes 1, 2 and 3
ISBN: N/A
EAN: N/A
Year: 2004
Pages: 704

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net