Preface 1
Chapter 1:Time Series Analysis 7
Multivariate time series analysis 8
Cointegration 8
Vector autoregressive models 12
VAR implementation example 15
Cointegrated VAR and VECM 19
Volatility modeling 23
GARCH modeling with the rugarch package 28
The standard GARCH model 28
The Exponential GARCH model(EGARCH) 31
The Threshold GARCH model(TGARCH) 33
Simulation and forecasting 34
Summary 36
References and reading list 36
Chapter 2:Factor Models 39
Arbitrage pricing theory 39
Implementation of APT 42
Fama-French three-factor model 42
Modeling in R 43
Data selection 43
Estimation of APT with principal component analysis 46
Estimation of the Fama-French model 48
Summary 56
References 57
Chapter 3:Forecasting Volume 59
Motivation 59
The intensity of trading 60
The volume forecasting model 61
Implementation in R 63
The data 64
Loading the data 66
The seasonal component 67
AR(1)estimation and forecasting 69
SETAR estimation and forecasting 70
Interpreting the results 72
Summary 74
References 74
Chapter 4:Bia Data-Advanced Analytics 77
Getting data from open sources 78
Introduction to big data analysis in R 83
K-means clustering on big data 84
Loading big matrices 84
Big data K-means clustering analysis 85
Big data linear regression analysis 89
Loading big data 89
Fitting a linear regression model on large datasets 90
Summary 91
References 91
Chapter 5:FX Derivatives 93
Terminology and notations 93
Currency options 96
Exchange options 99
Two-dimensional Wiener processes 100
The Margrabe formula 102
Application in R 106
Quanto options 109
Pricing formula for a call quanto 110
Pricing a call quanto in R 113
Summary 114
References 114
Chapter 6:Interest Rate Derivatives and Models 115
The Black model 116
Pricing a cap with Black's model 119
The Vasicek model 122
The Cox-Ingersoll-Ross model 128
Parameter estimation of interest rate models 132
Using the SMFI5 package 134
Summary 135
References 135
Chapter 7:Exotic Options 137
A general pricing approach 137
The role of dynamic hedging 138
How R can help a lot 138
A glance beyond vanillas 139
Greeks-the link back to the vanilla world 145
Pricing the Double-no-touch option 148
Another way to price the Double-no-touch option 160
The life of a Double-no-touch option-a simulation 161
Exotic options embedded in structured products 168
Summary 174
References 175
Chapter 8:Optimal Hedging 177
Hedging of derivatives 177
Market risk of derivatives 178
Static delta hedge 179
Dynamic delta hedge 179
Comparing the performance of delta hedging 185
Hedging in the presence of transaction costs 190
Optimization of the hedge 192
Optimal hedging in the case of absolute transaction costs 194
Optimal hedging in the case of relative transaction costs 196
Further extensions 198
Summary 199
References 199
Chapter 9:Fundamental Analysis 201
The basics of fundamental analysis 201
Collecting data 203
Revealing connections 207
Including multiple variables 208
Separating investment targets 209
Setting classification rules 215
Backtesting 217
Industry-specific investment 221
Summary 225
References 226
Chapter 10:Technical Analysis,Neural Networks,and Logoptimal Portfolios 227
Market efriciency 228
Technical analysis 228
The TA toolkit 229
Markets 230
Plotting charts-bitcoin 230
Built-in indicators 234
SMA and EMA 234
RSI 234
MACD 236
Candle patterns:key reversal 237
Evaluating the signals and managing the position 240
A word on money management 241
Wraping up 243
Neural networks 243
Forecasting bitcoin prices 245
Evaluation of the strategy 249
Logoptimal portfolios 249
A universally consistent,non-parametric investment strategy 250
Evaluation of the strategy 254
Summary 255
References 255
Chapter 11:Asset and Liability Management 257
Data preparation 258
Data source at first glance 260
Cash-flow generator functions 262
Preparing the cash-flow 265
Interest rate risk measurement 267
Liquidity risk measurement 271
Modeling non-maturity deposits 273
A Model of deposit interest rate development 273
Static replication of non-maturity deposits 278
Summary 283
References 283
Chapter 12:Capital Adequacy 285
Principles of the Basel Accords 286
Basel Ⅰ 286
Basel Ⅱ 287
Minimum capital requirements 287
Supervisory review 289
Transparency 290
Basel Ⅲ 290
Risk measures 292
Analytical VaR 294
Historical VaR 296
Monte-Carlo simulation 297
Risk categories 299
Market risk 299
Credit risk 305
Operational risk 311
Summary 313
References 313
Chapter 13:Systemic Risks 315
Systemic risk in a nutshell 315
The dataset used in our examples 317
Core-periphery decomposition 319
Implementation in R 321
Results 322
The Simulation method 323
The simulation 324
Implementation in R 325
Results 328
Possible interpretations and suggestions 332
Summary 332
References 333
Index 335