Inspecting Data with glimpse, summary, head, names, and dim
Table 1
Table
6 / 12
Table 1
Table
Table 1
| Function | What it shows | Data management question |
|---|---|---|
| `glimpse(data)` | Column names, types, and example values | Were variables imported with plausible types? |
| `summary(data)` | Basic summaries by variable | Are there obvious impossible values or excessive missingness? |
| `head(data)` | First rows of the dataset | Does the file look like the expected data export? |
| `names(data)` | Column names | Are key variables present and named as expected? |
| `dim(data)` | Number of rows and columns | Does the dataset have the expected size? |
| `str(data)` | Base R structure display | What is the internal structure of the object? |