R studio assignment help (boxplot)

Hi,
I have an assignment due and I am trying to make a boxplot however I have no clue how to do this on rstudio. I have a feeling it is very simple and wouldnt take much time for someone good with R. If you help I will give $20 CAD. Thanks

Hi, have a read.

ggplot2 box plot : Quick start guide - R software and data visualization - Easy Guides - Wiki - STHDA

Here's the simplest possible example.

boxplot(mtcars$mpg)

Created on 2023-11-15 with reprex v2.0.2

There are other ways to do it that have more bells and whistles, but this is the simplest.

Think about R as like school algebra: y = f(x) where there are three objects (R thingies are all objects, meaning they can be acted upon to achieve some result).

y is what is desired, in this case a boxplot
x is what is at hand, in this case the values of the continuous variable mpg contained in the data frame mtcars. The $sign is an operator object that connects the two, a process called subsetting.
f is the function to use to get from x to y