11
In R using the function, . . . . . . . . one can check the data type of vector.
A)
Typeof()
B)
Castof()
C)
Function()
D)
C()
Answer & Solution
Answer: Option
A
12
Attributes of an object (if any) can be accessed using the . . . . . . . . function.
A)
objects()
B)
attrib()
C)
attributes()
D)
obj()
Answer & Solution
Answer: Option
C
13
. . . . . . . . are similar to matrices but can have more than two dimensions.
A)
Functions
B)
Packages
C)
Arrays
D)
Columns
Answer & Solution
Answer: Option
C
14
The data type of the R-object becomes the data type of the . . . . . . . .
A)
Functions
B)
Packages
C)
Variables
D)
Lists
Answer & Solution
Answer: Option
C
15
Which function gives the list as output?
A)
Spline
B)
Matrix
C)
Vector
D)
Alphabet
Answer & Solution
Answer: Option
A
16
Which of the following is valid assignment?
A)
> x <- fact(c("yes", "yes", "no", "yes", "no"))
B)
> x <- factor(c("yes", "yes", "no", "yes", "no"))
C)
> x <- factor(factor("yes", "yes", "no", "yes", "no"))
D)
> x <- factor(factor("yes", "no", "no", "yes", "no"))
Answer & Solution
Answer: Option
B
17
Which of the following is a valid assignment?
A)
> m <- matrix(nrow = 2, ncol = 3)
B)
> m <- matrix(nrow = 2, ncol = 3.5)
C)
> m <- mat(nrow = 2, ncol = 3)
D)
> m <- mat(nrow = 2, ncol = 5)
Answer & Solution
Answer: Option
A
18
Which of the following is used for generating sequences?
A)
seq()
B)
sequence()
C)
order()
D)
orderasc()
Answer & Solution
Answer: Option
A
19
Point out the correct statement?
A)
Use explicit TRUE and FALSE values when indicating logical values
B)
rm command is used to remove objects in R
C)
R operates on named data structures
D)
All of the mentioned
Answer & Solution
Answer: Option
D
20
Factors are the r-objects which are created using a . . . . . . . .
A)
Vector
B)
Matrix
C)
Lists
D)
Array
Answer & Solution
Answer: Option
A