What Will Be The Output Of The Following R Codep Pre Langrsplus #284
What will be the output of the following R code?</p> <pre><code class="language-rsplus"> > x <- matrix(1:6, 2, 3) > x[1, , drop = FALSE] </code></pre>
This multiple choice question (MCQ) is related to the book/course gs gs110 R Language. It can also be found in gs gs110 R - Data Storage, Formats, Objects and Operations - Subsetting - Quiz No.1.
What will be the output of the following R code?
> x <- matrix(1:6, 2, 3) > x[1, , drop = FALSE]
[,1] [,2] [,3] [1,] 1 3 5
[,1] [,2] [,3] [1,] 2 3 5
[,1] [,2] [,3] [1,] 1 2 5
Error