Products & Services Solutions Academia Support User Community Company

Learn more about Statistics Toolbox   

wblrnd - Weibull random numbers

Syntax

R = wblrnd(A,B)
R = wblrnd(A,B,v)
R = wblrnd(A,B,m,n)

Description

R = wblrnd(A,B) generates random numbers for the Weibull distribution with scale parameter, A and shape parameter, B. The input arguments A and B can be either scalars or matrices. A and B, can be vectors, matrices, or multidimensional arrays that all have the same size. A scalar input is expanded to a constant array of the same size as the other input.

R = wblrnd(A,B,v) generates random numbers for the Weibull distribution with parameters A and B, where v is a row vector. If v is a 1-by-2 vector, R is a matrix with v(1) rows and v(2) columns. If v is 1-by-n, R is an n-dimensional array.

R = wblrnd(A,B,m,n) generates random numbers for the Weibull distribution with parameters A and B, where scalars m and n are the row and column dimensions of R.

Devroye [1] refers to the Weibull distribution with a single parameter; this is wblrnd with A = 1.

Examples

n1 = wblrnd(0.5:0.5:2,0.5:0.5:2)
n1 =
  0.0178  0.0860  2.5216  0.9124

n2 = wblrnd(1/2,1/2,[1 6])
n2 =
  0.0046  1.7214  2.2108  0.0367  0.0531  0.0917

References

[1] Devroye, L. Non-Uniform Random Variate Generation. New York: Springer-Verlag, 1986.

See Also

random, wblpdf, wblcdf, wblinv, wblstat, wblfit, wbllike

Weibull Distribution

  


Recommended Products

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.

 © 1984-2009- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS