Introduction to R Studio and Quarto

For Data Science and Statistics

R Saidi

The Tools Used in This Course

R R Studio Quarto

What are R and R Studio?

  • R is a statistical programming language

  • R Studio is an easy to use interface for R, which is an integrated development environment (IDE)

R R Studio

1

The R Studio IDE

1

What is Tidyverse?

The tidyverse is a collection of R packages designed for data science. All packages share an underlying design philosophy, grammar, and data structures. – tidyverse.org

Quarto document capability

Seamlessly render this quarto (markdown) document with:

  • text

  • code

  • plots

  • other output

Create a Visualization to Compare Baltimore Trash Volume (in tons) for 2015 and 2022 over the Months

Here is the code

ggplot(data = trash_bmore, aes(x = Month, y = `Weight(tons)`, fill = Month)) +
  geom_col() +
  theme_bw() +
  theme(axis.text.x = element_text(angle = 45)) +
  guides(fill = "none")+
  scale_fill_viridis_d(option = "plasma", name = "Month", direction = -1) +
  facet_wrap(~Year) +
  labs(title = "Baltimore Trash Volume (tons) Comparison for Years 2015 and 2022")

1

Plot the Bar Graph

1

Discuss the insights this plot shows