R
Programming
|
1) What is the default data type in which the data get stored in R ?
Numeric
2) What are the different data types in R ?
Numeric, Integer, Character, Complex, and Logical
3) What is the difference between a matrix and a dataframe?
A dataframe can contain heterogenous inputs and a matrix cannot.
4) ) If I concatenate a number and a character together, what will the class of the resulting vector be?
Character
5) If I concatenate a number and a Logical together, what will the class of the resulting vector be?
Number
6) What is the difference between seq(4) and seq_along(4)?
seq(4) produces a vector from 1 to 4 (c(1, 2, 3, 4)), whereas seq_along(4) produces a vector of length(4), or 1 (c(1)).
7) How missing values are represented in R?
Answer: NA, impossible values as NaN
8) Problem : x = function(a,b) { print a, print b} x(2) What will be the output of this function call?
Ans : [1] 2
Error: Argument missing – This is because of lazy evaluation
9) What is the use of the … parameter in while defining a function?
It will help us to call the other parameter functions into our function without having explicitly defined it.
10) What does tapply() function do?
It is used to compute the function() for the subset and give us the results based on a variable.
Get more Interview Question for below courses
- JavaTraining in Bangalore
- Devops Training in Bangalore
- AWS Training in Bangalore
- Android Training in Bangalore
- PythonTraining in Bangalore
- R Programming Training in Bangalore
- Software Testing Training in Bangalore
Original source from : isabellajoseph.blogspot.in