Step 1: Download the three files from Data.gov and place them in the directory created for this project.
Step 2: Delete the first few rows containing contact information in each excel sheet.
Step 3: Load in the appropriate libraries needed for this project.
Step 4: Read in the excel files into RStudio.
Step 5: Observe the unemployment dataset to see any irregularities or errors.
Step 6: Fix the error in the unemployment dataset regarding Colorado.
Step 7: Convert the “State” column to a factor.
Step 8: Remove any columns that are unnecessary.
Step 9: Filter the state and county data within the unemployment dataset.
Step 10: Convert the “county_fips” variable to a character type.
Step 11: Repeat steps 5 through 10 for the population and education datasets.
Step 12: In the education dataset, rename the columns with spaces, commas, and numbers to make formatting easier.
Step 13: Prep the mapping data using the urbanmapr package. Create new datasets for state and county data.
Step 14: Plot the data across all of the states.
Step 15: Filter out GA, OH, and TX and use bar graphs and scatterplots to compare the various quantaties.
Step 16: Use urbanmapr to show the differences in the counties in the states GA, OH, and TX.
\[Rate\:of\:Change = \frac{old - new}{old}*100\%\]
Below is the compilation of the different plots created to visualize the data in this project. Urbnmapr and ggplot were two packages used for visualizations. To see the codes used to generate the following plots, please refer here.
Figure 3 is a static visualization to show where the densly populated areas are in the United States. California is the most populated, with Texas, Florida and New York coming in next.
From 2010 to 2018, the coastal states, as well as, the western states had the best unemployment numbers by far. Then it was observed that those areas also had the largest increase in civilian labor force. Now, by observing Figure 4, one can see that the same areas are also growing the fastest. It appears that people do migrate where the jobs are. Of course, there are numerous other reasons such as state taxes, etc. but there is definitely a connection.
In Figure 11, the rate of change in population is plotted as a scatterplot ranging from 2010 to 2018. So not only is Texas the most populated out of the three states, it is also the fastest growing. According to the next figure below, Figure 12, Texas is also the state with the most unemployed people. As mentioned earlier, a plot showing the amount of people will not give a lot of valuable information. What would be more interesting and valuable is to see the rate in which the amount of people unemployed changes.
Here, Figure 14 communicates the same thing as Figure 13. Except Figure 14 shows the unemployment rate. This plot is very interesting. Georgia had the biggest drop in unemployment rate from the years 2010 to 2018. However, this could be due to Georgia starting with the largest unemployment rate out of the three states. Thus, Georgia does not seem to be as resilent to unemployment as it appeared in the plots before.
Now looking Figure 20, the unemployment rate distribution can be observed among the counties in the states in the year 2018. Both Texas and Ohio had the greatest unemployment rate in their southeast counties. However, Georgia experience the greatest unemployment rate in its central counties. Interestingly, non of the counties with the largest cities were shown to have the highest unemployment rate. Remember earlier, that the idea was that people moved to where the jobs were. While this may be true on a state level, on the county level it does not appear to be true.
Then by comparing Figure 27 with both figures 25 and 26, it appears that job opportunities really does influence where people live. Some counties even had a growth of 80% over the eight year span.
library(tidyverse)
library(readxl)
library(ggplot2)
library(urbnmapr)
unemployment <- read_excel("Unemployment.xls")
population <- read_excel("PopulationEstimates.xls")
education <- read_excel("Education.xls")
view(unemployment)
str(unemployment)
The results of the code above will not be shown in this report to save space, but it is recommended to run. Upon viewing the results, some important details that should be noticed are: the “FIPS” variable is a numeric vector and the “State” variable is a character vector instead of a factor. Before converting the “State” variable to a factor, check to see how many different factors the dataset contains.
table(unemployment$State)
##
## AK AL AR AZ CA Co CO CT DC DE FL GA HI IA ID IL IN KS KY LA
## 33 68 76 16 59 1 64 9 2 4 68 160 5 100 45 103 93 106 121 65
## MA MD ME MI MN MO MS MT NC ND NE NH NJ NM NV NY OH OK OR PA
## 15 25 17 84 88 116 83 57 101 54 94 11 22 34 18 63 89 78 37 68
## PR RI SC SD TN TX US UT VA VT WA WI WV WY
## 79 6 47 67 96 255 1 30 134 15 40 73 56 24
Notice that there is a “Co” and “CO” factor. This is most likely a typo error that occurred when the data was being inputed. Before proceeding, this error needs to be dealt with. To do this, find the location of the “Co” value, replace the “Co” value with “CO” ,and then check to ensure the factors are correct.
#Find the Co value
unemployment$State
#Change Co to CO
unemployment$State[254] <- "CO"
#Double Check
table(unemployment$State)
##
## AK AL AR AZ CA CO CT DC DE FL GA HI IA ID IL IN KS KY LA MA
## 33 68 76 16 59 65 9 2 4 68 160 5 100 45 103 93 106 121 65 15
## MD ME MI MN MO MS MT NC ND NE NH NJ NM NV NY OH OK OR PA PR
## 25 17 84 88 116 83 57 101 54 94 11 22 34 18 63 89 78 37 68 79
## RI SC SD TN TX US UT VA VT WA WI WV WY
## 6 47 67 96 255 1 30 134 15 40 73 56 24
#Convert State into a factor
unemployment$State <- as.factor(unemployment$State)
#Remove columns
unemployment <- select(unemployment, FIPS:Area_name, Civilian_labor_force_2010:Median_Household_Income_2017)
view(unemployment)
unemployment_state <- unemployment %>%
filter(FIPS %% 1000 == 0 & State != "US" & State != "PR") %>%
rename(county_fips = "FIPS", state = "State", state_name = "Area_name")
unemployment_county <- unemployment %>%
filter(FIPS %% 1000 != 0 & State != "US" & State != "PR") %>%
rename(county_fips = "FIPS", state = "State", state_name = "Area_name")
unemployment_state$county_fips <- as.character(unemployment_state$county_fips)
unemployment_county$county_fips <- as.character(unemployment_county$county_fips)
view(population)
str(unemployment)
table(population$State)
#Conver FIPS to numeric
population$FIPS <- as.numeric(population$FIPS)
#Convert State to a factor
population$State <- as.factor(population$State)
#Take out columns that aren't needed
population <- select(population, FIPS:Area_Name, POP_ESTIMATE_2010:POP_ESTIMATE_2018, Births_2010:Deaths_2018)
population_state <- population %>%
filter(FIPS %% 1000 == 0 & State != "US" & State != "PR") %>%
rename(county_fips = "FIPS", state = "State", state_name = "Area_Name")
population_county <- population %>%
filter(FIPS %% 1000 != 0 & State != "US" & State != "PR") %>%
rename(county_fips = "FIPS", state = "State", state_name = "Area_Name")
population_state$county_fips <- as.character(population_state$county_fips)
population_county$county_fips <- as.character(population_county$county_fips)
view(education)
str(education)
table(education$State)
#Adjust column names
names(education) <- str_replace_all(names(education), c(" " = "_", "," = "_", "-" = "_to_", "'"="", "__" = "_"))
view(education)
#Conver FIPS to numeric
education$FIPS_Code <- as.numeric(education$FIPS_Code)
#Convert State to a factor
education$State <- as.factor(education$State)
#Take out columns that aren't needed
education <- select(education, FIPS_Code:Area_name, Less_than_a_high_school_diploma_2000:Percent_of_adults_with_a_bachelors_degree_or_higher_2013_to_17)
education_state <- education %>%
filter(FIPS_Code %% 1000 == 0 & State != "US" & State != "PR") %>%
rename(county_fips = "FIPS_Code", state = "State", state_name = "Area_name")
education_county <- education %>%
filter(FIPS_Code %% 1000 != 0 & State != "US" & State != "PR") %>%
rename(county_fips = "FIPS_Code", state = "State", state_name = "Area_name")
education_state$county_fips <- as.character(education_state$county_fips)
education_county$county_fips <- as.character(education_county$county_fips)
#Create blank map of the US states
blank_states <- get_urbn_map("states", sf = TRUE)
head(blank_states)
blank_states <- rename(blank_states, state = "state_abbv")
blank_states$state <- as.factor(blank_states$state)
#Create blank map of the US counties
blank_counties <- get_urbn_map("counties", sf = TRUE)
#head(blank_map)
blank_counties <- rename(blank_counties, state = "state_abbv")
#Convert state to a factor
blank_counties$state <- as.factor(blank_counties$state)
blank_counties <- arrange(blank_counties, county_fips)
\[Rate\:of\:Change = \frac{old - new}{old}*100\%\]
FIGURE 1:
unemployment_state <- mutate(unemployment_state,
unemployment_percent_change = (Unemployment_rate_2018 - Unemployment_rate_2010)
/Unemployment_rate_2010)
left_join(blank_states,unemployment_state) %>%
ggplot() +
geom_sf(mapping = aes(fill = unemployment_percent_change),
color = "white", size = 0.2) +
geom_sf_text(aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::percent, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Percent",
x = "",
y = "",
title = "Change in Unemployment Rate from 2010 to 2018")
FIGURE 2:
unemployment_state <- mutate(unemployment_state,
laborforce_percent_change = (Civilian_labor_force_2018 - Civilian_labor_force_2010)
/Civilian_labor_force_2010)
left_join(blank_states,unemployment_state) %>%
ggplot() +
geom_sf(mapping = aes(fill = laborforce_percent_change),
color = "white", size = 0.2) +
geom_sf_text(aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::percent, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Percent",
x = "",
y = "",
title = "Percent of Change in Civilian Labor Force")
FIGURE 3:
left_join(blank_states,population_state) %>%
ggplot() +
geom_sf(mapping = aes(fill = POP_ESTIMATE_2018),
color = "white", size = 0.2) +
geom_sf_text(aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::comma, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Amount of People",
x = "",
y = "",
title = "Population Estimate 2018")
FIGURE 4:
population_state <- mutate(population_state,
population_percent_change = (POP_ESTIMATE_2018 - POP_ESTIMATE_2010)
/ POP_ESTIMATE_2010)
left_join(blank_states,population_state) %>%
ggplot() +
geom_sf(mapping = aes(fill = population_percent_change),
color = "white", size = 0.2) +
geom_sf_text(aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::percent, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Percent",
x = "",
y = "",
title = "Percent of Change in Population")
FIGURE 5:
education_state <- mutate(education_state,
High_school_or_less = Less_than_a_high_school_diploma_2013_to_17 +
High_school_diploma_only_2013_to_17)
left_join(blank_states,education_state, by = "state") %>%
ggplot() +
geom_sf(mapping = aes(fill = High_school_or_less),
color = "white", size = 0.2) +
geom_sf_text(aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::comma, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Amount of People",
x = "",
y = "",
title = "Number of People with a High School Education or Less 2017")
FIGURE 6:
left_join(blank_states,education_state, by = "state") %>%
ggplot() +
geom_sf(mapping = aes(fill = Bachelors_degree_or_higher_2013_to_17),
color = "white", size = 0.2) +
geom_sf_text(aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::comma, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Bachelors or Higher",
x = "",
y = "",
title = "Number of People with a Bachelors Degree or Higher 2017")
FIGURE 7:
education_state <- mutate(education_state,
highschool_or_less_percent_change = (High_school_or_less-(Less_than_a_high_school_diploma_2000 +
High_school_diploma_only_2000))
/(Less_than_a_high_school_diploma_2000 +
High_school_diploma_only_2000))
left_join(blank_states,education_state, by = "state") %>%
ggplot() +
geom_sf(mapping = aes(fill = highschool_or_less_percent_change),
color = "white", size = 0.2) +
geom_sf_text(aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::percent, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Percent of Change",
x = "",
y = "",
title = "Percent of Change for People with High School Diploma or Less")
FIGURE 8:
education_state <- mutate(education_state,
Bachelors_or_higher_percent_change = (Bachelors_degree_or_higher_2013_to_17
- Bachelors_degree_or_higher_2000)
/Bachelors_degree_or_higher_2000)
left_join(blank_states,education_state, by = "state") %>%
ggplot() +
geom_sf(mapping = aes(fill = Bachelors_or_higher_percent_change),
color = "white", size = 0.2) +
geom_sf_text(aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::percent, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Percent of Change",
x = "",
y = "",
title = "Percent of Change for People with a Bachelors Degree or Higher")
FIGURE 9:
left_join(blank_states,unemployment_state) %>%
ggplot() +
geom_sf(mapping = aes(fill = Median_Household_Income_2017),
color = "white", size = 0.2) +
geom_sf_text(aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::dollar, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Income",
x = "",
y = "",
title = "Median Household Income 2017")
unemployment_state <- filter(unemployment_state, state == "GA" |
state == "OH" | state == "TX")
population_state <- filter(population_state, state == "GA" |
state == "OH" | state == "TX")
education_state <- filter(education_state, state == "GA" |
state == "OH" | state == "TX")
blank_states <- filter(blank_states, state == "GA" |
state == "OH" | state == "TX")
# Joining them together
dataset_state <- left_join(unemployment_state, population_state)
dataset_state <- left_join(dataset_state, education_state)
#Mapping dataset for states
state_data <- left_join(blank_states, dataset_state)
#Before we filter out the data, remove Area_name from unemployment because it is inputed differently.
unemployment_county <- select(unemployment_county, county_fips:state, Civilian_labor_force_2010:Median_Household_Income_2017)
#view(unemployment)
unemployment_county <- filter(unemployment_county, state == "GA" |
state == "OH" | state == "TX")
population_county <- filter(population_county, state == "GA" |
state == "OH" | state == "TX")
education_county <- filter(education_county, state == "GA" |
state == "OH" | state == "TX")
blank_counties <- filter(blank_counties, state == "GA" |
state == "OH" | state == "TX")
# Joining them together
dataset_county <- left_join(unemployment_county, population_county)
dataset_county <- left_join(dataset_county, education_county)
dataset_county <- filter(dataset_county, !(state_name == "Georgia" |
state_name == "Ohio" | state_name == "Texas"))
#Mapping dataset for counties
county_data <- left_join(blank_counties, dataset_county, by = "county_fips")
FIGURE 10:
ggplot(data = state_data, aes(x = state_name, y = POP_ESTIMATE_2018)) +
geom_bar(stat = "identity", fill = "green4") +
scale_x_discrete(name = "State") +
scale_y_continuous(name = "Number of People", labels = scales::comma) +
ggtitle("Population of People 2018")
FIGURE 11:
state_data %>%
select(state_fips:state_name, POP_ESTIMATE_2010:POP_ESTIMATE_2018, geometry) %>%
rename(
"2010" = POP_ESTIMATE_2010,
"2011" = POP_ESTIMATE_2011,
"2012" = POP_ESTIMATE_2012,
"2013" = POP_ESTIMATE_2013,
"2014" = POP_ESTIMATE_2014,
"2015" = POP_ESTIMATE_2015,
"2016" = POP_ESTIMATE_2016,
"2017" = POP_ESTIMATE_2017,
"2018" = POP_ESTIMATE_2018
) %>%
gather(Year, Population, "2010":"2018") %>%
ggplot() +
geom_point(mapping = aes(x = Year, y = Population, color = state)) +
scale_x_discrete(name = "Year") +
scale_y_continuous(name = "Number of People", labels = scales::comma) +
facet_wrap(~state, nrow = 1) +
theme(axis.text.x = element_text(size = 8, angle = 50)) +
ggtitle("Change in Population 2010-2018")
FIGURE 12:
ggplot(data = state_data, aes(x = state_name, y = Unemployed_2018)) +
geom_bar(stat = "identity", fill = "green4") +
scale_x_discrete(name = "State") +
scale_y_continuous(name = "Number of People", labels = scales::comma) +
ggtitle("Number of Unemployed People 2018")
FIGURE 13:
state_data %>%
select(state_fips:state_name, Unemployed_2010, Unemployed_2011, Unemployed_2012,
Unemployed_2013, Unemployed_2014, Unemployed_2015, Unemployed_2016,
Unemployed_2017, Unemployed_2018) %>%
rename(
"2010" = Unemployed_2010,
"2011" = Unemployed_2011,
"2012" = Unemployed_2012,
"2013" = Unemployed_2013,
"2014" = Unemployed_2014,
"2015" = Unemployed_2015,
"2016" = Unemployed_2016,
"2017" = Unemployed_2017,
"2018" = Unemployed_2018
) %>%
gather(Year, Unemployed, "2010":"2018") %>%
ggplot() +
geom_point(mapping = aes(x = Year, y = Unemployed, color = state)) +
scale_x_discrete(name = "Year") +
scale_y_continuous(name = "Number of People", labels = scales::comma) +
facet_wrap(~state, nrow = 1) +
theme(axis.text.x = element_text(size = 8, angle = 50)) +
ggtitle("Change in Unemployment 2010 - 2018")
FIGURE 14:
state_data %>%
select(state_fips:state_name, Unemployment_rate_2010, Unemployment_rate_2011, Unemployment_rate_2012,
Unemployment_rate_2013, Unemployment_rate_2014, Unemployment_rate_2015, Unemployment_rate_2016,
Unemployment_rate_2017, Unemployment_rate_2018) %>%
rename(
"2010" = Unemployment_rate_2010,
"2011" = Unemployment_rate_2011,
"2012" = Unemployment_rate_2012,
"2013" = Unemployment_rate_2013,
"2014" = Unemployment_rate_2014,
"2015" = Unemployment_rate_2015,
"2016" = Unemployment_rate_2016,
"2017" = Unemployment_rate_2017,
"2018" = Unemployment_rate_2018
) %>%
gather(Year, Unemployment_rate, "2010":"2018") %>%
ggplot() +
geom_point(mapping = aes(x = Year, y = Unemployment_rate, color = state)) +
scale_x_discrete(name = "Year") +
scale_y_continuous(name = "Percent") +
facet_wrap(~state, nrow = 1) +
theme(axis.text.x = element_text(size = 8, angle = 50)) +
ggtitle("Change in Unemployment Rate 2010 - 2018")
FIGURE 15:
state_data %>%
select(state_fips:state_name, Less_than_a_high_school_diploma_2000: Bachelors_degree_or_higher_2000) %>%
rename(
"No High School Diploma 2000" = Less_than_a_high_school_diploma_2000,
"High School Diploma 2000" = High_school_diploma_only_2000,
"Some College 2000" = Some_college_or_associates_degree_2000,
"Bachelors or Higher 2000" = Bachelors_degree_or_higher_2000
) %>%
gather(Education, People, "No High School Diploma 2000":"Bachelors or Higher 2000") %>%
ggplot(mapping = aes(x = Education, y = People, fill = state)) +
geom_bar(stat="identity", position = "dodge", color = "black") +
scale_x_discrete(name = "Education") +
scale_y_continuous(name = "Number of People", labels = scales::comma) +
theme(axis.text.x = element_text(size = 8, angle = 0)) +
coord_flip() +
ggtitle("Amount of People with Different Education Levels, 2000")
FIGURE 16:
state_data %>%
select(state_fips:state_name, Percent_of_adults_with_less_than_a_high_school_diploma_2000:
Percent_of_adults_with_a_bachelors_degree_or_higher_2000) %>%
rename(
"No High School Diploma 2000" = Percent_of_adults_with_less_than_a_high_school_diploma_2000,
"High School Diploma 2000" = Percent_of_adults_with_a_high_school_diploma_only_2000,
"Some College 2000" = Percent_of_adults_completing_some_college_or_associates_degree_2000,
"Bachelors or Higher 2000" = Percent_of_adults_with_a_bachelors_degree_or_higher_2000
) %>%
gather(Education, People, "No High School Diploma 2000":"Bachelors or Higher 2000") %>%
ggplot(mapping = aes(x = Education, y = People, fill = state)) +
geom_bar(stat="identity", position = "dodge", color = "black") +
scale_x_discrete(name = "Education") +
scale_y_continuous(name = "Percent") +
theme(axis.text.x = element_text(size = 8, angle = 0)) +
coord_flip() +
ggtitle("Percent of Different Education Levels, 2000")
FIGURE 17:
state_data %>%
select(state_fips:state_name, Less_than_a_high_school_diploma_2013_to_17: Bachelors_degree_or_higher_2013_to_17) %>%
rename(
"No High School Diploma 2017" = Less_than_a_high_school_diploma_2013_to_17,
"High School Diploma 2017" = High_school_diploma_only_2013_to_17,
"Some College 2017" = Some_college_or_associates_degree_2013_to_17,
"Bachelors or Higher 2017" = Bachelors_degree_or_higher_2013_to_17
) %>%
gather(Education, People, "No High School Diploma 2017":"Bachelors or Higher 2017") %>%
ggplot(mapping = aes(x = Education, y = People, fill = state)) +
geom_bar(stat="identity", position = "dodge", color = "black") +
scale_x_discrete(name = "Education") +
scale_y_continuous(name = "Number of People", labels = scales::comma) +
theme(axis.text.x = element_text(size = 8, angle = 0)) +
coord_flip() +
ggtitle("Amount of People with Different Education Levels, 2017")
FIGURE 18:
state_data %>%
select(state_fips:state_name, Percent_of_adults_with_less_than_a_high_school_diploma_2013_to_17:
Percent_of_adults_with_a_bachelors_degree_or_higher_2013_to_17) %>%
rename(
"No High School Diploma 2017" = Percent_of_adults_with_less_than_a_high_school_diploma_2013_to_17,
"High School Diploma 2017" = Percent_of_adults_with_a_high_school_diploma_only_2013_to_17,
"Some College 2017" = Percent_of_adults_completing_some_college_or_associates_degree_2013_to_17,
"Bachelors or Higher 2017" = Percent_of_adults_with_a_bachelors_degree_or_higher_2013_to_17
) %>%
gather(Education, People, "No High School Diploma 2017":"Bachelors or Higher 2017") %>%
ggplot(mapping = aes(x = Education, y = People, fill = state)) +
geom_bar(stat="identity", position = "dodge", color = "black") +
scale_x_discrete(name = "Education") +
scale_y_continuous(name = "Percent") +
theme(axis.text.x = element_text(size = 8, angle = 0)) +
coord_flip() +
ggtitle("Percent of Different Education Levels, 2017")
FIGURE 19:
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = POP_ESTIMATE_2018),
color = "green", size = 0.05) +
geom_sf_text(data = state_data, aes(label = state), size = 3) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::comma, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Number of People",
x = "",
y = "",
title = "Population Estimate 2018")
FIGURE 20:
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = Unemployment_rate_2018),
color = "white", size = 0.05) +
geom_sf_text(data = state_data, aes(label = state), size = 3) +
coord_sf(datum = NA) +
scale_fill_gradient(low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Percent",
x = "",
y = "",
title = "Unemployment Rate 2018")
FIGURE 21:
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = Less_than_a_high_school_diploma_2000),
color = "white", size = 0.05) +
geom_sf_text(data = state_data, aes(label = state), size = 3) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::comma, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Number of People",
x = "",
y = "",
title = "Amount of People Without a High School Diploma 2000")
FIGURE 22:
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = Bachelors_degree_or_higher_2000),
color = "white", size = 0.05) +
geom_sf_text(data = state_data, aes(label = state), size = 3) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::comma, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Number of People",
x = "",
y = "",
title = "Amount of People with At Least a Bachelors Degree 2000")
FIGURE 23:
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = Less_than_a_high_school_diploma_2013_to_17),
color = "white", size = 0.05) +
geom_sf_text(data = state_data, aes(label = state), size = 3) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::comma, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Number of People",
x = "",
y = "",
title = "Amount of People Without a High School Diploma 2017")
FIGURE 24:
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = Bachelors_degree_or_higher_2013_to_17),
color = "white", size = 0.05) +
geom_sf_text(data = state_data, aes(label = state), size = 3) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::comma, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Number of People",
x = "",
y = "",
title = "Amount of People with At Least a Bachelors Degree 2017")
FIGURE 25:
county_data <- mutate(county_data,
unemployment_percent_change = (Unemployment_rate_2018 - Unemployment_rate_2010)
/Unemployment_rate_2010)
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = unemployment_percent_change),
color = "white", size = 0.2) +
geom_sf_text(data = state_data, aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::percent, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Percent",
x = "",
y = "",
title = "Change in Unemployment Rate from 2010 to 2018")
FIGURE 26:
county_data <- mutate(county_data,
laborforce_percent_change = (Civilian_labor_force_2018 - Civilian_labor_force_2010)
/Civilian_labor_force_2010)
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = laborforce_percent_change),
color = "white", size = 0.2) +
geom_sf_text(data = state_data, aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::percent, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Percent",
x = "",
y = "",
title = "Percent of Change in Civilian Labor Force")
FIGURE 27:
county_data <- mutate(county_data,
population_percent_change = (POP_ESTIMATE_2018 - POP_ESTIMATE_2010)
/ POP_ESTIMATE_2010)
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = population_percent_change),
color = "white", size = 0.2) +
geom_sf_text(data = state_data, aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::percent, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Percent",
x = "",
y = "",
title = "Percent of Change in Population")
FIGURE 28:
county_data <- mutate(county_data,
highschool_or_less_percent_change = ((Less_than_a_high_school_diploma_2013_to_17
+ High_school_diploma_only_2013_to_17)
- (Less_than_a_high_school_diploma_2000 + High_school_diploma_only_2000))
/ (Less_than_a_high_school_diploma_2000 +
High_school_diploma_only_2000))
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = highschool_or_less_percent_change),
color = "white", size = 0.2) +
geom_sf_text(data = state_data, aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::percent, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Percent of Change",
x = "",
y = "",
title = "Percent of Change for People with High School Diploma or Less")
FIGURE 29:
county_data <- mutate(county_data,
Bachelors_or_higher_percent_change = (Bachelors_degree_or_higher_2013_to_17
- Bachelors_degree_or_higher_2000)
/Bachelors_degree_or_higher_2000)
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = Bachelors_or_higher_percent_change),
color = "white", size = 0.2) +
geom_sf_text(data = state_data, aes(label = state), size = 1.5) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::percent, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Percent of Change",
x = "",
y = "",
title = "Percent of Change for People with a Bachelors Degree or Higher")
FIGURE 30:
county_data %>%
ggplot() +
geom_sf(mapping = aes(fill = Median_Household_Income_2017),
color = "white", size = 0.05) +
geom_sf_text(data = state_data, aes(label = state), size = 3) +
coord_sf(datum = NA) +
scale_fill_gradient(labels = scales::dollar, low = "#98CF90", high = "#1a2e19" ) +
labs(fill = "Income",
x = "",
y = "",
title = "Median Household Income 2017")