Posts

Showing posts from March, 2025

Module # 10 assignment

Image
Issaiah. Jennings  Module # 10 assignment For this project, I used the economics dataset in R to analyze unemployment trends from 2000 to 2008 using ggplot2. First, I added a year column to make it easier to categorize the data by time. I then created a line plot to visualize the unemployment rate over time, providing a clear look at how the number of unemployed individuals changed each month. Next, I generated another line plot to examine the median duration of unemployment, highlighting periods when people stayed unemployed longer. Finally, I created a scatter plot with paths to compare the unemployment rate and median duration, using color to distinguish different years. Visualizing time series data with ggplot2 helped uncover trends and patterns that might not be as obvious in raw numbers. The line plots made it easy to track changes over time, while the scatter plot provided insights into the relationship between unemployment and duration. Customizing the colors and layout im...

Module # 9 assignment

Image
Issaiah Jennings Module # 9 assignment Multivariable visualization effectively displays multiple relationships in a single plot without overcrowding. Color helps differentiate categorical variables like cylinders, while size encoding adds another dimension by representing weight. However, size differences can sometimes be misleading, and too many categories may make color distinctions harder to interpret. Labels and legends are kept simple to enhance clarity, while minimal styling (theme_minimal()) reduces distractions. Accuracy is maintained by properly scaling size and color, ensuring the data isn’t misleading. Aesthetic choices, like distinct colors and transparency, improve readability, and the scatter plot format keeps the visualization functional without overwhelming the viewer. > # Load necessary libraries > library(ggplot2) >  > # Create a multivariate scatter plot > ggplot(mtcars, aes(x = hp, y = mpg, color = as.factor(cyl), size = wt)) + +   geom...

Module # 8 Correlation Analysis and ggplot2

Image
Issaiah Jennings Module # 8 Correlation Analysis and ggplot2 I used correlation analysis through scatter plots to explore relationships between different variables in the mtcars dataset. > # Load necessary libraries > library(ggplot2) > library(gridExtra) >  > # Use mtcars dataset > data(mtcars) >  > # Create scatter plots with regression lines > p1 <- ggplot(mtcars, aes(x=hp, y=mpg)) +  +   geom_point() +  +   geom_smooth(method = "lm", color = "white") + # Add white regression line +   ggtitle("HP vs MPG") + +   theme_minimal() >  > p2 <- ggplot(mtcars, aes(x=wt, y=mpg)) +  +   geom_point() +  +   geom_smooth(method = "lm", color = "white") + # Add white regression line +   ggtitle("Weight vs MPG") + +   theme_minimal() >  > p3 <- ggplot(mtcars, aes(x=disp, y=mpg)) +  +   geom_point() +  +  ...