cpp_resize | R Documentation |
Resizes mat according to new_height and new_width parameters.
mat |
a numeric matrix. |
new_height |
an unsigned integer, giving the new height of returned mat. Default is 0 for no change. |
new_width |
an unsigned integer, giving the new width of returned mat. Default is 0 for no change. |
add_noise |
logical, if true adds normal noise when at least one new dimension is larger than original mat dimensions Rcpp::rnorm() function is used. Default is true. |
bg |
double, mean value of the background added if add_noise is true. Default is 0. |
sd |
double, standard deviation of the background added if add_noise is true. Default is 0. |
a resized matrix with padding background if new_height or new_width is larger than original mat dimensions.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.