Shiny App to Plot US Phillips Curves
The app is running on this server at Shinyapps.io
Data were downloaded interactively from FRED
Files:
-
server.R: Source code for server
-
ui.R: Source code for user interface
-
UNRATE.csv: Unemployment data from FRED
-
CPIAUCNS.csv: CPI data from FRED
-
README.md: This file
-
pitch.Rmd: R Markdown for 5-slide presentation
-
pitch.html: HTML for 5-slide presentation
Extensions to consider writing in the future:
-
Allow user to choose time offset for unemployment (a point-in-time reading) vs. inflation (a 12-month change, so where should it overlap the unemployment rate?)
-
Allow a shifting baseline for inflation (e.g., subtract the last N-years average inflation rate from inflation, where N is maybe a slider choice).
-
Allow user to choose different series to plot (most obviously, wage growth instead of inflation, but more generally there could be other labor market tightness indicators besides unemployment, and anyhow there's no reason to confine oneself to Phillips curves).
-
Allow user to choose different countries for which to plot Phillips curves.
-
Allow user to configure definition of inflation (e.g. 6 months instead of a year, PCE deflator instead of CPI, maybe an exponential moving average?).
-
Allow user to fit lines and/or curves (log-log?)DONE for linear & quadratic, but could be others -
Allow connecting adjacent points in scatter plots.
-
Allow labeling of data (e.g. by year) in scatter plots.
-
Allow aggregating data in scatter plots (e.g. use annual instead of monthly).
-
Pull in data directly from sources rather than using my canned series.
-
Change the display so that it is clearer which parts of the scatter plot have more densely clustered points.DONE