ABSTRACT

Reproducible Finance with R: Code Flows and Shiny Apps for Portfolio Analysis is a unique introduction to data science for investment management that explores the three major R/finance coding paradigms, emphasizes data visualization, and explains how to build a cohesive suite of functioning Shiny applications. The full source code, asset price data and live Shiny applications are available at reproduciblefinance.com. The ideal reader works in finance or wants to work in finance and has a desire to learn R code and Shiny through simple, yet practical real-world examples.

The book begins with the first step in data science: importing and wrangling data, which in the investment context means importing asset prices, converting to returns, and constructing a portfolio. The next section covers risk and tackles descriptive statistics such as standard deviation, skewness, kurtosis, and their rolling histories. The third section focuses on portfolio theory, analyzing the Sharpe Ratio, CAPM, and Fama French models. The book concludes with applications for finding individual asset contribution to risk and for running Monte Carlo simulations. For each of these tasks, the three major coding paradigms are explored and the work is wrapped into interactive Shiny dashboards.

 

 

 

chapter 1|6 pages

Introduction

chapter |2 pages

Returns

chapter 2|20 pages

Asset Prices to Returns

chapter 3|18 pages

Building a Portfolio

chapter |2 pages

Concluding Returns

chapter |2 pages

Risk

chapter 4|22 pages

Standard Deviation

chapter 5|14 pages

Skewness

chapter 6|18 pages

Kurtosis

chapter |2 pages

Concluding Risk

chapter |2 pages

Portfolio Theory

chapter 7|20 pages

Sharpe Ratio

chapter 8|24 pages

CAPM

chapter 9|22 pages

Fama-French Factor Model

chapter |2 pages

Concluding Portfolio Theory

chapter |2 pages

Practice and Applications

chapter 10|24 pages

Component Contribution to Standard Deviation

chapter 11|20 pages

Monte Carlo Simulation

chapter |2 pages

Concluding Practice Applications