indicator <-fredr_series_observations(series_id = "ICNSA",
observation_start = as.Date("2019-01-01"))
# plotting data
ggplot(indicator) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('15-09-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(mapping = aes(x=date,y=value/1000000), color = "red4") +
labs(title = "Initial Claims _ Insured Unemployed Persons _ National",
subtitle = str_glue("from {min(indicator$date)} through {max(indicator$date)}\nNot Seasonally Adjusted"),
x="Weekly", y="Millions of Persons",
caption = "Data source: FRED Federal Reserve.\nIllustration by @JoeLongSanDiego")+
theme_economist()
## Continued Claims (Insured Unemployment) (CCNSA)
indicator <-fredr_series_observations(series_id = "CCNSA",
observation_start = as.Date("2019-01-01"))
# plotting data
ggplot(indicator) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('15-09-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(mapping = aes(x=date,y=value/1000000), color = "red4") +
labs(title = "Continued Claims _ Insured Unemployed Persons _ National",
subtitle = str_glue("from {min(indicator$date)} through {max(indicator$date)}\nNot Seasonally Adjusted"),
x="Weekly", y="Millions of Persons",
caption = "Data source: FRED Federal Reserve Bank of St. Louis.\nIllustration by @JoeLongSanDiego")+
theme_economist()
indicator <-fredr_series_observations(series_id = "LAUST060000000000004",
observation_start = as.Date("2019-01-01"))
# plotting data
ggplot(indicator) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(mapping = aes(x=date,y=value/1000000), color = "red4") +
labs(title = "Unemployed Persons in California",
subtitle = str_glue("Monthly from {min(indicator$date)} through {max(indicator$date)}\nNot Seasonally Adjusted"),
x="Monthly", y="Millions of Persons",
caption = "Data source: FRED Federal Reserve Bank of St. Louis.\nIllustration by @JoeLongSanDiego")+
theme_economist()
indicator <-fredr_series_observations(series_id = "LAUST060000000000005",
observation_start = as.Date("2019-01-01"))
# plotting data
ggplot(indicator) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-08-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(mapping = aes(x=date,y=value/1000000), color = "red4") +
labs(title = "Employed Persons in California",
subtitle = str_glue("Monthly from {min(indicator$date)} through {max(indicator$date)}\nNot Seasonally Adjusted"),
x="Monthly", y="Millions of Persons",
caption = "Data source: FRED Federal Reserve Bank of St. Louis.\nIllustration by @JoeLongSanDiego")+
theme_economist()
ca_claims <-
"CAICLAIMS" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
ca_claims %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('15-09-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "blue",size=1) +
labs(
x = "",
y = "",
title = "New Unemployment Claims _ California",
caption = "Data source: FRED Philadelphia Federal Reserve\nIllustration by @JoeLongSanDiego",
subtitle = str_glue("{min(ca_claims$date)} through {max(ca_claims$date)}")
) +
theme_economist() +
scale_y_continuous(labels = scales::comma)
library(lubridate)
library(dplyr)
ca_claims$year <- year(ca_claims$date)
ca_claims$month <- month(ca_claims$date)
ca_claims$week <- week(ca_claims$date)
ca_month <- ca_claims %>%
group_by(year,month)%>%
summarise(count =sum(claims))
## `summarise()` regrouping output by 'year' (override with `.groups` argument)
ggplot(data=ca_month,aes(x=reorder(month,year),y = count,fill=month)) +
geom_bar(stat = "identity")+
labs( title = "New Unemployment Claims in California",
subtitle = str_glue("Monthly from {min(ca_month$year)} through {max(ca_month$year)}\nSeptember 2020 is unfinished"),
caption = "Data source: FRED Federal Reserve Bank of St. Louis\nIllustration by @JoeLongSanDiego",
y = "", x = "")
ca_month %>%
kable() %>%
kable_styling(bootstrap_options = c("striped", "hover", "condensed")) %>%
column_spec(3, T, color = "blue" ) %>%
column_spec(1:2, T, color = "green" )
year | month | count |
---|---|---|
2019 | 1 | 197785 |
2019 | 2 | 171719 |
2019 | 3 | 201469 |
2019 | 4 | 159868 |
2019 | 5 | 153713 |
2019 | 6 | 201622 |
2019 | 7 | 152034 |
2019 | 8 | 181829 |
2019 | 9 | 133808 |
2019 | 10 | 153780 |
2019 | 11 | 211487 |
2019 | 12 | 180199 |
2020 | 1 | 199167 |
2020 | 2 | 203952 |
2020 | 3 | 1345649 |
2020 | 4 | 2427989 |
2020 | 5 | 1205251 |
2020 | 6 | 1059116 |
2020 | 7 | 1083952 |
2020 | 8 | 1031385 |
2020 | 9 | 469408 |
sdurn <-
"CASAND5URN" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
sdurn %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-08-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "blue",size=1) +
labs(
x = "",
y = "",
title = "Unemployment Rate _ San Diego (CASAND5URN)",
subtitle = str_glue("From {min(sdurn$date)} through {max(sdurn$date)}"),
caption = "Data source: FRED Federal Reserve Bank of St. Louis\nIllustration by @JoeLongSanDiego") +
theme_economist() +
scale_y_continuous(labels = scales::comma)
sdun <-
"LAUCN060730000000004" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
sdun %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "blue",size=1) +
labs(
x = "",
y = "",
title = "Unemployment Population _ San Diego (LAUCN060730000000004)",
subtitle = str_glue("From {min(sdun$date)} through {max(sdun$date)}"),
caption = "Data source: FRED Federal Reserve Bank of St. Louis\nIllustration by @JoeLongSanDiego") +
theme_economist() +
scale_y_continuous(labels = scales::comma)
sdlabor <-
"CASAND5LFN" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
sdlabor %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "blue",size=1) +
labs(
x = "",
y = "",
title = "Civilian Labor Force in San Diego County, CA (CASAND5LFN)",
subtitle = str_glue("From {min(sdlabor$date)} through {max(sdlabor$date)}"),
caption = "Data source: FRED Federal Reserve Bank of St. Louis\nIllustration by @JoeLongSanDiego") +
theme_economist() +
scale_y_continuous(labels = scales::comma)
rsurn <-
"CARIVE5URN" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
rsurn %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "darkgreen",size=1) +
labs(
x = "",
y = "",
title = "Unemployment Rate _ Riverside County (CARIVE5URN)",
subtitle = str_glue("From {min(rsurn$date)} through {max(rsurn$date)}"),
caption = "Data source: FRED Federal Reserve Bank of St. Louis\nIllustration by @JoeLongSanDiego") +
theme_economist()+
scale_y_continuous(labels = scales::comma)
rsun <-
"LAUCN060650000000004" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
rsun %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "darkgreen",size=1) +
labs(
x = "",
y = "",
title = "Unemployment Population _ Riverside County (LAUCN060650000000004)",
subtitle = str_glue("From {min(rsun$date)} through {max(rsun$date)}"),
caption = "Data source: FRED Federal Reserve Bank of St. Louis\nIllustration by @JoeLongSanDiego") +
theme_economist()+
scale_y_continuous(labels = scales::comma)
#---------------------
rslabor <-
"CARIVE5LFN" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
rslabor %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "darkgreen",size=1) +
labs(
x = "",
y = "",
title = "Civilian Labor Force in Riverside County, CA (CARIVE5LFN)",
subtitle = str_glue("From {min(rslabor$date)} through {max(rslabor$date)}"),
caption = "Data source: FRED Federal Reserve Bank of St. Louis\nIllustration by @JoeLongSanDiego") +
theme_economist()+
scale_y_continuous(labels = scales::comma)
ocurn <-
"CAORAN7URN" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
ocurn %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "blue",size=1) +
labs(
x = "",
y = "",
title = "Unemployment Rate _ Orange County (CAORAN7URN)",
subtitle = str_glue("From {min(ocurn$date)} through {max(ocurn$date)}"),
caption = "Data source: FRED Federal Reserve\nIllustration by @JoeLongSanDiego") +
theme_economist()+
scale_y_continuous(labels = scales::comma)
#--------------------------------
ocun <-
"LAUCN060590000000004" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
ocun %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "blue",size=1) +
labs(
x = "",
y = "",
title = "Unemployment Population _ Orange County (LAUCN060590000000004)",
subtitle = str_glue("From {min(ocun$date)} through {max(ocun$date)}"),
caption = "Data source: FRED Federal Reserve\nIllustration by @JoeLongSanDiego") +
theme_economist()+
scale_y_continuous(labels = scales::comma)
#------------------------
oclabor <-
"CAORAN7LFN" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
oclabor %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "blue",size=1) +
labs(
x = "",
y = "",
title = "Civilian Labor Force in Orange County, CA (CAORAN7LFN)",
subtitle = str_glue("From {min(oclabor$date)} through {max(oclabor$date)}"),
caption = "Data source: FRED Federal Reserve\nIllustration by @JoeLongSanDiego") +
theme_economist()+
scale_y_continuous(labels = scales::comma)
laurn <-
"CALOSA7URN" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
laurn %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "darkblue",size=1) +
labs(
x = "",
y = "",
title = "Unemployment Rate _ Los Angeles County (CALOSA7URN)",
subtitle = str_glue("From {min(laurn$date)} through {max(laurn$date)}"),
caption = "Data source: FRED Federal Reserve\nIllustration by @JoeLongSanDiego") +
theme_economist() +
scale_y_continuous(labels = scales::comma)
#--------------------------------
laun <-
"LAUCN060370000000004" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
laun %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "darkblue",size=1) +
labs(
x = "",
y = "",
title = "Unemployment Population _ Los Angeles County (LAUCN060370000000004)",
subtitle = str_glue("From {min(laun$date)} through {max(laun$date)}"),
caption = "Data source: FRED Federal Reserve\nIllustration by @JoeLongSanDiego") +
theme_economist() +
scale_y_continuous(labels = scales::comma)
#------------------------
lalabor <-
"CALOSA7LFN" %>%
tq_get(get = "economic.data",
from = "2019-01-01") %>%
rename(claims = price)
oclabor %>%
ggplot(aes(x = date, y = claims)) +
geom_rect(aes(xmin= dmy('01-01-2020'), xmax=dmy('01-07-2020'), ymin = -Inf, ymax = Inf),
fill = "lightyellow", alpha = 0.02)+
geom_line(color = "blue",size=1) +
labs(
x = "",
y = "",
title = "Civilian Labor Force in Los Angeles County, CA (CALOSA7LFN)",
subtitle = str_glue("From {min(lalabor$date)} through {max(lalabor$date)}"),
caption = "Data source: FRED Federal Reserve\nIllustration by @JoeLongSanDiego") +
theme_economist() +
scale_y_continuous(labels = scales::comma)