Data Types

🔢 Let’s start with the building blocks! In this section, you’ll explore R’s basic Data Types. Understanding these is key to writing code that behaves the way you expect. Think of it as learning the alphabet before writing full sentences.

Numeric (numeric/double)

Numbers with or without decimal points, stored as double-precision by default.

Integer (integer)

Whole numbers stored as integers using the L suffix.

Character (character)

Text values enclosed in quotes, representing sequences of characters.

Logical (logical)

Values representing truth: TRUE, FALSE, or the result of a comparison.

Raw (raw)

Binary data stored as raw bytes, mostly for low-level operations.

Null (NULL)

Represents the absence of a value or an undefined object — similar to None in Python.