knitr::opts_chunk$set( collapse = TRUE, comment = "#>", fig.path = "man/figures/README-", out.width = "100%", fig.width=6, fig.height=7 )
The goal of {ihpdr} is to fetch data from the International House Price Database, compiled by the Federal Reserve Bank of Dallas.
You can install the released version of {ihpdr} from CRAN with:
install.packages("ihpdr")
Or install the development version from GitHub with:
# install.packages("devtools") devtools::install_github("kvasilopoulos/ihpdr")
This is a basic example which shows you how to download the data:
# Raw Data ihpdr::ihpd_get() # Exuberance Indicators ~ bsadf ihpdr::ihpd_get("bsadf") # Get the release dates ihpdr::ihpd_release_dates()
library(tidyverse)
raw_data <- ihpdr::ihpd_get() ggplot(raw_data, aes(Date, rhpi)) + geom_line(size = 0.7) + scale_x_date(date_labels = "%y") + facet_wrap(~country, ncol = 4)
bsadf_data <- ihpdr::ihpd_get("bsadf") bsadf_data %>% dplyr::filter(type == "rhpi", lag == 1) %>% ggplot() + geom_line(aes(Date, value), size = 0.7) + geom_line(aes(Date, crit), col = "red", size = 0.7) + scale_x_date(date_labels = "%y") + facet_wrap(~country, ncol = 4) + theme_bw()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.