Learn R Programming

matricks (version 0.8.2)

runif_same_dims: Create matrix of random values with dimensions copied from an existing matrix

Description

Create matrix of random values with dimensions copied from an existing matrix

Usage

runif_same_dims(mat, min = 0, max = 1)

Arguments

mat

matrix

min

lower limit of the distribution. Must be finite.

max

upper limit of the distribution. Must be finite.

Value

a matrix

Examples

Run this code
# NOT RUN {
mat <- matrix(0, 3, 3)
runif_same_dims(mat)
# }

Run the code above in your browser using DataLab