mirror of
https://github.com/wassname/catalyst.git
synced 2026-06-27 23:21:36 +08:00
351 lines
20 KiB
HTML
351 lines
20 KiB
HTML
|
|
|
|
<!DOCTYPE html>
|
|
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
|
|
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
|
|
<head>
|
|
<meta charset="utf-8">
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
|
|
<title>Features — Catalyst 0.4 documentation</title>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
|
|
|
|
|
|
|
|
|
|
|
|
<link rel="index" title="Index"
|
|
href="genindex.html"/>
|
|
<link rel="search" title="Search" href="search.html"/>
|
|
<link rel="top" title="Catalyst 0.4 documentation" href="index.html"/>
|
|
<link rel="next" title="Example Algorithms" href="example-algos.html"/>
|
|
<link rel="prev" title="Live Trading" href="live-trading.html"/>
|
|
|
|
|
|
<script src="_static/js/modernizr.min.js"></script>
|
|
|
|
</head>
|
|
|
|
<body class="wy-body-for-nav" role="document">
|
|
|
|
|
|
<div class="wy-grid-for-nav">
|
|
|
|
|
|
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
<div class="wy-side-scroll">
|
|
<div class="wy-side-nav-search">
|
|
|
|
|
|
|
|
<a href="index.html" class="icon icon-home"> Catalyst
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div role="search">
|
|
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
<input type="text" name="q" placeholder="Search docs" />
|
|
<input type="hidden" name="check_keywords" value="yes" />
|
|
<input type="hidden" name="area" value="default" />
|
|
</form>
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<ul class="current">
|
|
<li class="toctree-l1"><a class="reference internal" href="install.html">Install</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="beginner-tutorial.html">Catalyst Beginner Tutorial</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="live-trading.html">Live Trading</a></li>
|
|
<li class="toctree-l1 current"><a class="current reference internal" href="#">Features</a><ul>
|
|
<li class="toctree-l2"><a class="reference internal" href="#current-functionality">Current Functionality</a></li>
|
|
<li class="toctree-l2"><a class="reference internal" href="#upcoming-features">Upcoming features</a></li>
|
|
<li class="toctree-l2"><a class="reference internal" href="#naming-convention">Naming Convention</a></li>
|
|
</ul>
|
|
</li>
|
|
<li class="toctree-l1"><a class="reference internal" href="example-algos.html">Example Algorithms</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="utilities.html">Utilities</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="videos.html">Videos</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="resources.html">Resources</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="development-guidelines.html">Development Guidelines</a></li>
|
|
<li class="toctree-l1"><a class="reference internal" href="releases.html">Release Notes</a></li>
|
|
</ul>
|
|
|
|
|
|
|
|
</div>
|
|
</div>
|
|
</nav>
|
|
|
|
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
|
|
|
|
|
|
<nav class="wy-nav-top" role="navigation" aria-label="top navigation">
|
|
|
|
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
<a href="index.html">Catalyst</a>
|
|
|
|
</nav>
|
|
|
|
|
|
|
|
<div class="wy-nav-content">
|
|
<div class="rst-content">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div role="navigation" aria-label="breadcrumbs navigation">
|
|
|
|
<ul class="wy-breadcrumbs">
|
|
|
|
<li><a href="index.html">Docs</a> »</li>
|
|
|
|
<li>Features</li>
|
|
|
|
|
|
<li class="wy-breadcrumbs-aside">
|
|
|
|
|
|
<a href="_sources/features.rst.txt" rel="nofollow"> View page source</a>
|
|
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
|
|
<hr/>
|
|
</div>
|
|
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
<div itemprop="articleBody">
|
|
|
|
<div class="section" id="features">
|
|
<h1>Features<a class="headerlink" href="#features" title="Permalink to this headline">¶</a></h1>
|
|
<p>This page describes the features that Catalyst provides in the current version,
|
|
and what is planned for future releases.</p>
|
|
<div class="section" id="current-functionality">
|
|
<h2>Current Functionality<a class="headerlink" href="#current-functionality" title="Permalink to this headline">¶</a></h2>
|
|
<ul class="simple">
|
|
<li>Backtesting and live-trading modes to run your trading algorithms, with a
|
|
seamless transition between the two.</li>
|
|
<li>Paper trading simulates order in live-trading mode.</li>
|
|
<li>Support for 3 exchanges: Bitfinex, Bittrex and Poloniex in both modes
|
|
(backtesting and live-trading). Historical data for backtesting is provided
|
|
with daily resolution for all three exchanges, and minute resolution for
|
|
Bitfinex and Poloniex. No minute-resolution data is currently available for
|
|
Bittrex. Refer to
|
|
<a class="reference external" href="https://www.enigma.co/catalyst/status">Catalyst Market Coverage</a> for
|
|
details.</li>
|
|
<li>Interface with over 90 exchanges available in live and paper trading modes.</li>
|
|
<li>Granular commission models which closely simulates each exchange fee
|
|
structure in backtesting and paper trading.</li>
|
|
<li>Standardized naming convention for all asset pairs trading on any exchange in
|
|
the form <code class="docutils literal"><span class="pre">{market_currency}_{base_currency}</span></code>. See
|
|
<a class="reference internal" href="#naming"><span class="std std-ref">Naming Convention</span></a>.</li>
|
|
<li>Output of performance statistics based on Pandas DataFrames to integrate
|
|
nicely into the existing PyData ecosystem.</li>
|
|
<li>Support for accessing multiple exchanges per algorithm, which opens the door
|
|
to cross-exchange arbitrage opportunities.</li>
|
|
<li>Support for running multiple algorithms on the same exchange independently of
|
|
one another. Catalyst performance tracker stores just enough data to allow
|
|
algorithms to run independently while still sharing critical data through
|
|
exchanges.</li>
|
|
<li>Benchmark defaults to Bitcoin price (btc_usdt in Poloniex exchange) for the
|
|
purpose of comparing performance across trading algorithms. A custom benchmark
|
|
can be specified through <code class="docutils literal"><span class="pre">set_benchmark()</span></code> (but see
|
|
<a class="reference external" href="https://github.com/enigmampc/catalyst/issues/86">issue #86</a>).</li>
|
|
<li>Support for MacOS, Linux and Windows installations.</li>
|
|
<li>Support for Python2 and Python3.</li>
|
|
</ul>
|
|
<p>For additional details on the functionality added on recent releases, see the
|
|
<a class="reference internal" href="releases.html"><span class="doc">Release Notes</span></a>.</p>
|
|
</div>
|
|
<div class="section" id="upcoming-features">
|
|
<h2>Upcoming features<a class="headerlink" href="#upcoming-features" title="Permalink to this headline">¶</a></h2>
|
|
<ul class="simple">
|
|
<li>Additional datasets beyond pricing data (Q1 2018)</li>
|
|
<li>API documentation (Q1 2018)</li>
|
|
<li>Support for decentralized exchanges (Q1 2018)</li>
|
|
<li>Support for data ingestion of community-contributed data sets (Q1 2018)</li>
|
|
<li>Pipeline support (Q1 2018)</li>
|
|
<li>Web UI (Q2 2018)</li>
|
|
</ul>
|
|
<blockquote>
|
|
<div></div></blockquote>
|
|
</div>
|
|
<div class="section" id="naming-convention">
|
|
<span id="naming"></span><h2>Naming Convention<a class="headerlink" href="#naming-convention" title="Permalink to this headline">¶</a></h2>
|
|
<p>Catalyst introduces a standardized naming convention for all asset pairs
|
|
trading on any exchange in the following form:</p>
|
|
<blockquote>
|
|
<div><strong>{market_currency}_{base_currency}</strong></div></blockquote>
|
|
<p>Where {market_currency} is the asset to be traded using {base_currency} as
|
|
the reference, both written in lowercase and separated with an underscore.</p>
|
|
<p>This standardization is needed to overcome the lack of consistency in the
|
|
naming of assets across different exchanges, and making it easier to the user
|
|
to refer to the asset pairs that you want to trade.</p>
|
|
<p>Catalyst maintains a <a class="reference external" href="https://www.enigma.co/catalyst/status">Market Coverage Overview</a>
|
|
where you can check the mapping between Catalyst naming pairs and that of each
|
|
exchange. Catalyst will always expect in all its functions that you will refer to
|
|
the asset pairs by using the Catalyst naming convention.</p>
|
|
<p>If at any point, you input the wrong name for an asset pair, you will get an error
|
|
of that pair not found in the given exchange, and a list of pairs available on that exchange:</p>
|
|
<div class="highlight-bash"><div class="highlight"><pre><span></span>$ catalyst ingest-exchange -x poloniex -i btc_usd
|
|
</pre></div>
|
|
</div>
|
|
<div class="highlight-python"><div class="highlight"><pre><span></span><span class="n">Ingesting</span> <span class="n">exchange</span> <span class="n">bundle</span> <span class="n">poloniex</span><span class="o">...</span>
|
|
<span class="n">Error</span> <span class="n">traceback</span><span class="p">:</span> <span class="o">/</span><span class="n">Volumes</span><span class="o">/</span><span class="n">Data</span><span class="o">/</span><span class="n">Users</span><span class="o">/</span><span class="n">victoris</span><span class="o">/</span><span class="n">Desktop</span><span class="o">/</span><span class="n">Enigma</span><span class="o">/</span><span class="n">user</span><span class="o">-</span><span class="n">install</span><span class="o">/</span><span class="n">catalyst</span><span class="o">-</span><span class="n">dev</span><span class="o">/</span><span class="n">catalyst</span><span class="o">/</span><span class="n">exchange</span><span class="o">/</span><span class="n">exchange</span><span class="o">.</span><span class="n">py</span> <span class="p">(</span><span class="n">line</span> <span class="mi">175</span><span class="p">)</span>
|
|
<span class="n">SymbolNotFoundOnExchange</span><span class="p">:</span> <span class="n">Symbol</span> <span class="n">btc_usd</span> <span class="ow">not</span> <span class="n">found</span> <span class="n">on</span> <span class="n">exchange</span> <span class="n">Poloniex</span><span class="o">.</span>
|
|
<span class="n">Choose</span> <span class="n">from</span><span class="p">:</span> <span class="p">[</span><span class="s1">'rep_usdt'</span><span class="p">,</span> <span class="s1">'gno_btc'</span><span class="p">,</span> <span class="s1">'xvc_btc'</span><span class="p">,</span> <span class="s1">'pink_btc'</span><span class="p">,</span> <span class="s1">'sys_btc'</span><span class="p">,</span>
|
|
<span class="s1">'emc2_btc'</span><span class="p">,</span> <span class="s1">'rads_btc'</span><span class="p">,</span> <span class="s1">'note_btc'</span><span class="p">,</span> <span class="s1">'maid_btc'</span><span class="p">,</span> <span class="s1">'bch_btc'</span><span class="p">,</span> <span class="s1">'gnt_btc'</span><span class="p">,</span>
|
|
<span class="s1">'bcn_btc'</span><span class="p">,</span> <span class="s1">'rep_btc'</span><span class="p">,</span> <span class="s1">'bcy_btc'</span><span class="p">,</span> <span class="s1">'cvc_btc'</span><span class="p">,</span> <span class="s1">'nxt_xmr'</span><span class="p">,</span> <span class="s1">'zec_usdt'</span><span class="p">,</span>
|
|
<span class="s1">'fct_btc'</span><span class="p">,</span> <span class="s1">'gas_btc'</span><span class="p">,</span> <span class="s1">'pot_btc'</span><span class="p">,</span> <span class="s1">'eth_usdt'</span><span class="p">,</span> <span class="s1">'btc_usdt'</span><span class="p">,</span> <span class="s1">'lbc_btc'</span><span class="p">,</span>
|
|
<span class="s1">'dcr_btc'</span><span class="p">,</span> <span class="s1">'etc_usdt'</span><span class="p">,</span> <span class="s1">'omg_eth'</span><span class="p">,</span> <span class="s1">'amp_btc'</span><span class="p">,</span> <span class="s1">'xpm_btc'</span><span class="p">,</span> <span class="s1">'nxt_btc'</span><span class="p">,</span>
|
|
<span class="s1">'vtc_btc'</span><span class="p">,</span> <span class="s1">'steem_eth'</span><span class="p">,</span> <span class="s1">'blk_xmr'</span><span class="p">,</span> <span class="s1">'pasc_btc'</span><span class="p">,</span> <span class="s1">'zec_xmr'</span><span class="p">,</span> <span class="s1">'grc_btc'</span><span class="p">,</span>
|
|
<span class="s1">'nxc_btc'</span><span class="p">,</span> <span class="s1">'btcd_btc'</span><span class="p">,</span> <span class="s1">'ltc_btc'</span><span class="p">,</span> <span class="s1">'dash_btc'</span><span class="p">,</span> <span class="s1">'naut_btc'</span><span class="p">,</span> <span class="s1">'zec_eth'</span><span class="p">,</span>
|
|
<span class="s1">'zec_btc'</span><span class="p">,</span> <span class="s1">'burst_btc'</span><span class="p">,</span> <span class="s1">'zrx_eth'</span><span class="p">,</span> <span class="s1">'bela_btc'</span><span class="p">,</span> <span class="s1">'steem_btc'</span><span class="p">,</span> <span class="s1">'etc_btc'</span><span class="p">,</span>
|
|
<span class="s1">'eth_btc'</span><span class="p">,</span> <span class="s1">'huc_btc'</span><span class="p">,</span> <span class="s1">'strat_btc'</span><span class="p">,</span> <span class="s1">'lsk_btc'</span><span class="p">,</span> <span class="s1">'exp_btc'</span><span class="p">,</span> <span class="s1">'clam_btc'</span><span class="p">,</span>
|
|
<span class="s1">'rep_eth'</span><span class="p">,</span> <span class="s1">'dash_xmr'</span><span class="p">,</span> <span class="s1">'cvc_eth'</span><span class="p">,</span> <span class="s1">'bch_usdt'</span><span class="p">,</span> <span class="s1">'zrx_btc'</span><span class="p">,</span> <span class="s1">'dash_usdt'</span><span class="p">,</span>
|
|
<span class="s1">'blk_btc'</span><span class="p">,</span> <span class="s1">'xrp_btc'</span><span class="p">,</span> <span class="s1">'nxt_usdt'</span><span class="p">,</span> <span class="s1">'neos_btc'</span><span class="p">,</span> <span class="s1">'omg_btc'</span><span class="p">,</span> <span class="s1">'bts_btc'</span><span class="p">,</span>
|
|
<span class="s1">'doge_btc'</span><span class="p">,</span> <span class="s1">'gnt_eth'</span><span class="p">,</span> <span class="s1">'sbd_btc'</span><span class="p">,</span> <span class="s1">'gno_eth'</span><span class="p">,</span> <span class="s1">'xcp_btc'</span><span class="p">,</span> <span class="s1">'ltc_usdt'</span><span class="p">,</span>
|
|
<span class="s1">'btm_btc'</span><span class="p">,</span> <span class="s1">'xmr_usdt'</span><span class="p">,</span> <span class="s1">'lsk_eth'</span><span class="p">,</span> <span class="s1">'omni_btc'</span><span class="p">,</span> <span class="s1">'nav_btc'</span><span class="p">,</span> <span class="s1">'fldc_btc'</span><span class="p">,</span>
|
|
<span class="s1">'ppc_btc'</span><span class="p">,</span> <span class="s1">'xbc_btc'</span><span class="p">,</span> <span class="s1">'dgb_btc'</span><span class="p">,</span> <span class="s1">'sc_btc'</span><span class="p">,</span> <span class="s1">'btcd_xmr'</span><span class="p">,</span> <span class="s1">'vrc_btc'</span><span class="p">,</span>
|
|
<span class="s1">'ric_btc'</span><span class="p">,</span> <span class="s1">'str_btc'</span><span class="p">,</span> <span class="s1">'maid_xmr'</span><span class="p">,</span> <span class="s1">'xmr_btc'</span><span class="p">,</span> <span class="s1">'sjcx_btc'</span><span class="p">,</span> <span class="s1">'via_btc'</span><span class="p">,</span>
|
|
<span class="s1">'xem_btc'</span><span class="p">,</span> <span class="s1">'nmc_btc'</span><span class="p">,</span> <span class="s1">'etc_eth'</span><span class="p">,</span> <span class="s1">'ltc_xmr'</span><span class="p">,</span> <span class="s1">'ardr_btc'</span><span class="p">,</span> <span class="s1">'gas_eth'</span><span class="p">,</span>
|
|
<span class="s1">'flo_btc'</span><span class="p">,</span> <span class="s1">'xrp_usdt'</span><span class="p">,</span> <span class="s1">'game_btc'</span><span class="p">,</span> <span class="s1">'bch_eth'</span><span class="p">,</span> <span class="s1">'bcn_xmr'</span><span class="p">,</span> <span class="s1">'str_usdt'</span><span class="p">]</span>
|
|
</pre></div>
|
|
</div>
|
|
<p>In the example above, exchange Poloniex does not use USD, but uses instead the
|
|
USDT cryptocurrency asset that is issued on the Bitcoin blockchain via the Omni
|
|
Layer Protocol. Each USDT unit is backed by a U.S Dollar held in the reserves of
|
|
Tether Limited. USDT can be transferred, stored, and spent, just like bitcoins
|
|
or any other cryptocurrency. Given its 1:1 mapping to the USD, is a viable alternative.</p>
|
|
<div class="highlight-bash"><div class="highlight"><pre><span></span>$ catalyst ingest-exchange -x poloniex -i btc_usdt
|
|
</pre></div>
|
|
</div>
|
|
<div class="highlight-python"><div class="highlight"><pre><span></span><span class="n">Ingesting</span> <span class="n">exchange</span> <span class="n">bundle</span> <span class="n">poloniex</span><span class="o">...</span>
|
|
<span class="p">[</span><span class="o">====================================</span><span class="p">]</span> <span class="n">Fetching</span> <span class="n">poloniex</span> <span class="n">daily</span> <span class="n">candles</span><span class="p">:</span> <span class="p">:</span> <span class="mi">100</span><span class="o">%</span>
|
|
</pre></div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
</div>
|
|
<div class="articleComments">
|
|
|
|
</div>
|
|
</div>
|
|
<footer>
|
|
|
|
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
|
|
|
|
<a href="example-algos.html" class="btn btn-neutral float-right" title="Example Algorithms" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
|
|
|
|
|
|
<a href="live-trading.html" class="btn btn-neutral" title="Live Trading" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
|
|
|
|
</div>
|
|
|
|
|
|
<hr/>
|
|
|
|
<div role="contentinfo">
|
|
<p>
|
|
© Copyright 2018, Enigma MPC, Inc..
|
|
|
|
</p>
|
|
</div>
|
|
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/snide/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
|
|
|
|
</footer>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
</section>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
var DOCUMENTATION_OPTIONS = {
|
|
URL_ROOT:'./',
|
|
VERSION:'0.4',
|
|
COLLAPSE_INDEX:false,
|
|
FILE_SUFFIX:'.html',
|
|
HAS_SOURCE: true,
|
|
SOURCELINK_SUFFIX: '.txt'
|
|
};
|
|
</script>
|
|
<script type="text/javascript" src="_static/jquery.js"></script>
|
|
<script type="text/javascript" src="_static/underscore.js"></script>
|
|
<script type="text/javascript" src="_static/doctools.js"></script>
|
|
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript" src="_static/js/theme.js"></script>
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
jQuery(function () {
|
|
SphinxRtdTheme.StickyNav.enable();
|
|
});
|
|
</script>
|
|
|
|
|
|
</body>
|
|
</html> |