Register Now

Login

Lost Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

What will be the output of the following R code?
> x < – matrix(1:6, 2, 3)
> x[1, 2]

What will be the output of the following R code?
> x < - matrix(1:6, 2, 3)
> x[1, 2]
a) 3
b) 2
c) 1
d) 0

Answer: a
Explanation: Matrices can be subsetted in the usual way with (i,j) type indices where i is the row and j is the column numbers.

Join The Discussion