Posts

Showing posts from March, 2026

Module # 10 assignment

 For this week I worked with ggplot2 and messed around with time series data to see how it actually looks over time. The hot dog contest example was kinda cool because you can clearly see which years had record performances instead of just looking at numbers. Then with the economics dataset, the line graphs made it way easier to see how things like unemployment change over time and how different variables relate to each other. I feel like visualization makes a big difference with time series data because you can instantly spot trends, patterns, or anything weird going on. Without graphs it would honestly just be a bunch of numbers that are harder to understand. Using ggplot2 also makes everything look cleaner and more organized, so it just makes the data way easier to read and interpret.

Module # 9 assignment

Image
  For this visualization I used the mtcars dataset in R because it has multiple variables about different cars that make it good for a multivariate plot. In my graph I compared vehicle weight and miles per gallon to see how fuel efficiency changes, while also using color to show the number of cylinders, point size to represent horsepower, and faceting to separate cars by the number of gears. The plot shows that heavier cars generally have lower MPG, while lighter cars tend to be more fuel efficient, and cars with more cylinders and higher horsepower usually have worse fuel economy. Using a multivariate visualization was helpful because it lets you see several relationships in the data at the same time instead of looking at multiple separate charts. I also tried to apply some of the design principles from the module like contrast with different colors for cylinders, alignment with clearly labeled axes, and balance by keeping the layout simple so the relationships in the data are...

Module # 8 Correlation Analysis and ggplot2

 library(ggplot2) # use built-in dataset data(mtcars) # scatter plot with regression line ggplot(mtcars, aes(x = hp, y = mpg)) +   geom_point(color = "steelblue", size = 3) +   stat_smooth(method = "lm", se = FALSE, color = "black") +   labs(     title = "Relationship Between Horsepower and Fuel Efficiency",     x = "Horsepower",     y = "Miles Per Gallon"   ) +   theme_minimal() I used the built-in mtcars dataset in R to explore the relationship between horsepower and miles per gallon using a scatter plot with a regression line. The visualization shows a clear negative relationship, meaning cars with higher horsepower tend to have lower fuel efficiency. Using a simple layout with clear labels and minimal colors follows Few’s design recommendations by making the relationship between variables easy to interpret.