1 Import stock prices of your choice

2 Convert prices to returns by quarterly

## # A tibble: 60 × 3
##    asset date       returns
##    <chr> <date>       <dbl>
##  1 AAPL  2012-03-30  0.377 
##  2 AAPL  2012-06-29 -0.0263
##  3 AAPL  2012-09-28  0.137 
##  4 AAPL  2012-12-31 -0.221 
##  5 AAPL  2013-03-28 -0.178 
##  6 AAPL  2013-06-28 -0.103 
##  7 AAPL  2013-09-30  0.191 
##  8 AAPL  2013-12-31  0.169 
##  9 AAPL  2014-03-31 -0.0383
## 10 AAPL  2014-06-30  0.198 
## # … with 50 more rows

3 Make plot

4 Interpret the plot

This plot tells us that AAPL and NFLX would have made a positive return of about 15% and 12% respectively. GOOG on the other hand would have netted you a -2% return over the same period of time.

5 Change the global chunck options

Hide the code, messages, and warnings