rand: Return matrices of pseudorandom values.

Description Usage Arguments Details Value Author(s) References Examples

Description

Generate matrices of pseudorandom values.

Usage

1
2
  rand(m,n)
  randn(m,n)

Arguments

m

Number of matrix rows.

n

Number of matrix columns.

Details

Function rand returns a matrix containing pseudorandom values drawn from the standard uniform distribution (using runif). Function randn returns a matrix containing pseudorandom values drawn from the standard normal distribution (using rnorm).

Value

An m x n numeric matrix.

Author(s)

Peter Carbonetto peter.carbonetto@gmail.com

References

P. Carbonetto and M. Stephens (2012). Scalable variational inference for Bayesian variable selection in regression, and its accuracy in genetic association studies. Bayesian Analysis 7, 73–108.

Examples

1
2
  x <- rand(10,5)
  y <- randn(10,5)


Search within the varbvs package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.