menu

Data Types and Variables in R

Data Types and Variables in R - Important Points


11. Which of the following data types is used to represent not-a-number values in R?

A. NA

B. NaN

C. Inf

D. #NAME?

Discuss Work Space

Answer: option b

Explanation:

NaN is used in R to represent not-a-number values.

12. Which of the following data types is used to represent positive infinity in R?

A. NA

B. NaN

C. Inf

D. #NAME?

Discuss Work Space

Answer: option c

Explanation:

Inf is used in R to represent positive infinity.

13. Which of the following data types is used to represent negative infinity in R?

A. NA

B. NaN

C. Inf

D. #NAME?

Discuss Work Space

Answer: option d

Explanation:

-Inf is used in R to represent negative infinity.

14. What is the maximum length of a vector in R?

A. 2^31-1

B. 2^32-1

C. 2^63-1

D. There is no maximum length

Discuss Work Space

Answer: option a

Explanation:

The maximum length of a vector in R is 2^31-1.

15. Which of the following functions is used to check the data type of a variable in R?

A. typeof()

B. class()

C. str()

D. summary()

Discuss Work Space

Answer: option b

Explanation:

The class() function is used to check the data type of a variable in R.


Subscribe for Latest Career Trends
Subscribe Now
Use AI and ChatGPT for Career Guidance

Unlock Your Future

Join Now
Worried for Placements in 2024?

Join FAST TRACK Course

Join Now
Supercharge Your SUCCESS

Join All in One Placement Mock Tests-2024

Join Now