1/3/2020

Data

data("LifeCycleSavings")
head (LifeCycleSavings)
##              sr pop15 pop75     dpi ddpi
## Australia 11.43 29.35  2.87 2329.68 2.87
## Austria   12.07 23.32  4.41 1507.99 3.93
## Belgium   13.17 23.80  4.43 2108.47 3.82
## Bolivia    5.75 41.89  1.67  189.13 0.22
## Brazil    12.88 42.19  0.83  728.47 4.56
## Canada     8.79 31.72  2.85 2982.88 2.43

Loading necessary libraries

library(ggplot2)
library(plotly)
## Warning: package 'plotly' was built under R version 3.6.2

Plot

plot_ly(LifeCycleSavings, x= ~pop75, y = ~dpi) %>% layout(title = "Life Cycle Savings",font=8)

Conclusion

  • The data shows that as the percentage population of over 75 year olds goes up the savings real per-capita disposable income increases