The bubble
package and the bitcoinFinance
package are the companion materials for my textbook titled Quantitative Finance with R and Cryptocurrencies. This book organizes the materials that I developed over time for the Perm Summer/Winter School on Blockchain and CryptoEconomics, as well as for my course in Numerical methods for finance using R. The book's companion website can be found here.
The bubble
package implements several models proposed to test for financial bubbles and explosive behaviour. These tests span several fields of research,
from economics to econophysics, from statistics to computer science.
Note that the functions computing the DS LPPLS Confidence and Trust indicators and the critical values for the GSADF test require a lot of time, even with parallel computing. An optimized version would require coding these functions using C++: given that this goes beyond the scope of my courses, this was not done, but it is left to the interested reader as a (hopefully) interesting exercise.
You can install the package using the commands:
if (!require("devtools")) install.packages("devtools")
devtools::install_github("deanfantazzini/bubble")