About Crypto Market Cap
The Crypto Market Cap dataset by CoinGecko tracks the market cap of cryptocurrencies. The data covers 620 cryptocurrencies that are supported by QuantConnect, starts in 28 April 2013, and is delivered on a daily frequency. This dataset is created by scraping CoinGecko's Market Chart.
About CoinGecko
CoinGecko was founded in 2014 by TM Lee (CEO) and Bobby Ong (COO) with the mission to democratize the access of crypto data and empower users with actionable insights. We also deep dive into the crypto space to deliver valuable insights to our users through our cryptocurrency reports, as well as our publications, newsletter, and more.
About QuantConnect
QuantConnect was founded in 2012 to serve quants everywhere with the best possible algorithmic trading technology. Seeking to disrupt a notoriously closed-source industry, QuantConnect takes a radically open-source approach to algorithmic trading. Through the QuantConnect web platform, more than 50,000 quants are served every month.
Algorithm Example
from AlgorithmImports import *
class CoinGeckoAlgorithm(QCAlgorithm):
def initialize(self) -> None:
self.set_start_date(2018, 4, 4) # Set Start Date
self.set_end_date(2018, 4, 6) # Set End Date
# Request BTCUSD crypto data for trading
self.crypto_symbol = self.add_crypto("BTCUSD").symbol
# Request CoinGecko Market Cap data of BTC for trade signal generation
self.custom_data_symbol = self.add_data(CoinGecko, "BTC").symbol
# Use RollingWindow to save the last 2 market cap data for capital flow analysis
self.window = RollingWindow[CoinGecko](2)
def on_data(self, slice: Slice) -> None:
# Trade based on updated market cap data
data = slice.get(CoinGecko)
if data and self.custom_data_symbol in data:
# Update RollingWindow for updated comparison
self.window.add(data[self.custom_data_symbol])
if not self.window.is_ready:
return
# Buy BTCUSD if the market cap of BTC is increasing, which suggests the capital flow towards BTC market and drive up the demand
if self.window[0].market_cap > self.window[1].market_cap:
self.set_holdings(self.crypto_symbol, 1)
# Sell otherwise, since the capital is flowing out and the demand of BTC lowered
else:
self.set_holdings(self.crypto_symbol, -1)
def on_order_event(self, orderEvent: OrderEvent) -> None:
if orderEvent.status == OrderStatus.FILLED:
self.debug(f'Purchased Stock: {orderEvent.symbol}')
Example Applications
The CoinGecko Crypto Market Cap dataset provide information on the size of the crypto coin and can be used to compare the size of one coin to another. Examples include the following strategies:
- Construct a major crypto index fund.
- Invest on the cryptos with the fastest growth in market size.
- Red flag stop when there might be a crypto bank run.
Pricing
Cloud Access
Using CoinGecko Crypto Market Cap data in the QuantConnect Cloud for your backtesting and live trading purposes.
Explore Other Datasets
Upcoming Splits
Dataset by EOD Historical Data
US Equity Coarse Universe
Dataset by QuantConnect
Binance Crypto Price Data
Dataset by CoinAPI