Sprint 2 - RobertoLF/EC601Project GitHub Wiki

CryptoCompare API

Why CryptoCompare?

  • Free version provides full historical price data on a variety of cryptocurrencies.
  • API documentation is easy to follow and quick to set up (<15 minutes).
  • 100,000 calls/month limit is more than sufficient for purposes of project.
  • Capability to automate trades (outside scope of project, but a nice feature to have if project is to be turned into a real product in the future).

Some Example Results

Decomposing Time Series

Purpose of Decomposing Time Series

  • Decomposing is the process of splitting a time series into 3 separate components: trend, seasonality, and a residual series.
  • Decomposition of a time series and working with the residual series is required to determine the presence of short-term correlation.

Decomposition Process

  • Statsmodels library: Python module that provides functions for the estimation of many different statistical models, as well as for conducting statistical tests, and statistical data exploration.
  • seasonal_decompose() is a useful method within the statsmodel library that helps us decompose the time series.
  • A decomposed time series can be represented using either an additive or multiplicative model.
    • General guideline is to use an additive model when the seasonal variation is relatively constant over time, and use a multiplicative model when there is a trend present.
    • The seasonal_decompose() requires that either an additive or multiplicative model be specified as a parameter and we chose additive given that BTC prices are trending upwards.

Result

Autocorrelation Model

We are using the ARIMA (AutoRegressive Integrated Moving Average) model from the statsmodel library.

This method allows us to fit our previously found residual series to an autoregressive process of the order of our choosing. To find the appropriate order for our model we first plotted the partial auto correlation function. A partial autocorrelation function is the amount of correlation between a variable and a lag of itself that is not explained by correlations at all lower-order-lags.

The number of lags that represent most of the partial autocorrelation correlation that is statistically significant is an appropriate value for the order of the autocorrelation function.

Sprint 3 Objectives

  • Revisit methods of time series decomposition and compare results with other methods.
  • Use autoregressive coefficients to calculate Adjusted Market Inefficiency Metric (AMIM) for Bitcoin
  • If time, begin implementing machine learning model for predicting price of a cryptocurrency.