This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Inspired by the work of Rich Falk-Wallace | |
library(tidyverse) | |
library(tidyquant) | |
library(timetk) | |
library(readxl) | |
library(plotly) | |
library(scales) | |
library(formattable) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
```{r, include = FALSE} | |
library(XML) | |
library(tidyverse) | |
library(tidyquant) | |
library(timetk) | |
library(readxl) | |
library(plotly) | |
library(scales) | |
library(fredr) | |
library(Quandl) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
```{r include = FALSE} | |
library(tidyverse) | |
library(tidyquant) | |
library(timetk) | |
library(readxl) | |
library(plotly) | |
library(scales) | |
library(formattable) | |
library(fredr) | |
library(gt) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
```{r, include = FALSE} | |
library(tidyverse) | |
library(tidyquant) | |
library(timetk) | |
library(scales) | |
library(fredr) | |
library(gt) | |
library(gtExtras) | |
library(janitor) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Setup | |
```{r, include = FALSE} | |
library(tidyverse) | |
library(tidyquant) | |
library(timetk) | |
library(scales) | |
library(janitor) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
```{r, setup} | |
library(tidyverse) | |
library(timetk) | |
library(tidyquant) | |
library(readxl) | |
library(janitor) | |
library(gt) | |
library(gtExtras) | |
library(priceR) | |
library(scales) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Packages and setup | |
```{r setup, include=FALSE} | |
library(tidyverse) # the fundamentals | |
library(lubridate) # working with dates | |
library(timetk) # time series Swiss Army Knife, not used today but worth a look | |
library(tidyquant) # great finance functions and FRED importer | |
library(readxl) | |
library(scales) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(tidyverse) | |
library(timetk) | |
library(tidyquant) | |
library(readxl) | |
library(janitor) | |
url <- "https://www2.census.gov/programs-surveys/demo/tables/families/time-series/adults/ad3-25-34.xls" | |
destfile <- "ad3_25_34.xls" | |
curl::curl_download(url, destfile) | |
read_excel(destfile, skip = 7) %>% | |
slice(1:56) %>% |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fed_assets_on_bs <- | |
"WALCL" %>% | |
tq_get(get = "economic.data") %>% | |
summarise_by_time( | |
.date_var = date, | |
.by = "months", | |
monthly_assets = mean(price) | |
) | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
```{r} | |
library(tidyverse) | |
library(tidyquant) | |
library(timetk) | |
library(readxl) | |
library(plotly) | |
library(scales) | |
library(formattable) | |
library(fredr) | |
library(broom) |
NewerOlder