R - Produce Empty Matrix
- Create empty matrix with 10 rows and 3 columns WITH NA’s
empty_matrix <- matrix(, nrow=10, ncol=3)
- Create empty matrix with 10 rows and 3 columns WITH Zeros
empty_matrix <- matrix(0, nrow=10, ncol=3)
Feedback
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.