Instruction: Demonstrate how to create a basic scatter plot using ggplot2 with a dataset containing 'height' and 'weight' columns.
Context: This question tests the candidate's ability to use ggplot2 for basic data visualization tasks. It evaluates the candidate's familiarity with one of the most popular visualization packages in R, essential for data analysis and insights presentation.
Official answer available
Preview the opening of the answer, then unlock the full walkthrough.
To demonstrate creating a basic scatter plot with ggplot2 using a dataset with 'height' and 'weight' columns, let me walk you through the steps and the rationale behind it. First, let's assume we have a dataset named health_data loaded in R, with two columns of interest: height and weight.
```R Load the necessary library library(ggplot2)...