Description Usage Arguments Value Examples
View source: R/matrix_functions.R
Creates an example sparse matrix.
1 | create_example_sparse_matrix(n_row, n_col, p_zero = 0.8, matrix_values = 1:9)
|
n_row |
number of rows in matrix |
n_col |
number of columns in matrix |
p_zero |
(optional, default 0.8) proportion of entries to set to zero (in expectation) |
matrix_values |
(optional, default 1:9) a vector of numeric values from which to sample |
A random matrix of dimension n_row by n_col.
1 | create_example_sparse_matrix(10, 5)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.