![]() |
VOOZH | about |
In this article, we will discuss how to fill the empty matrix with values in R Programming Language. First, let's create an empty matrix.
Syntax:
matrix_name[row,column]=value.
Where, row and column are the numbers in which the value is occupied.
Example:
Output:
👁 ImageWe can replace with same value for all empty value in a matrix, by using [,].
Example
Output:
👁 ImageEven a range can be inserted.
Example
Output:
👁 Image