Trading bot for BitMex.
The author is not responsible for any damage caused by this software.
- Swithable strategy
- Back test
- Connect testnet
- Stub trading
- Channel Breakout
- Cross SMA
- RCI
- Open Close Cross Strategy
- Trading View Strategy
- Python: 3.6.5
$ brew install ta-lib
$ git clone https://github.com/noda-sin/ebisu.git
$ cd ebisu/
$ pip install -r requirements.txt$ wget http://prdownloads.sourceforge.net/ta-lib/ta-lib-0.4.0-src.tar.gz $ tar xvzf ta-lib-0.4.0-src.tar.gz $ cd ta-lib/ $ ./configure --prefix=/usr $ make $ sudo make install $ git clone https://github.com/noda-sin/ebisu.git $ cd ebisu/ $ pip install -r requirements.txt
Set BitMex's API key with the environment variables BITMEX_APIKEY and BITMEX_SECRET as shown below.
$ vi ~/.bash_profile export BITMEX_APIKEY=*********** export BITMEX_SECRET=***********
If you want to notify LINE, set LINE's API key to the environment variable LINE_APIKEY.
$ vi ~/.bash_profile export LINE_APIKEY=***********
$ python main.py --strategy STRATEGY
By changing the value of STRATEGY you can switch strategies to use.
$ python main.py --strategy Doten
$ python main.py --strategy Doten
It is possible to trade with testnet.
$ python main.py --demo --strategy Doten
$ python main.py --test --strategy Doten
$ python main.py --hyperopt --strategy Doten
$ python main.py --stub --strategy Doten
You can add strategy by creating a new class in src / strategy.py as follows.
For example, this is a random entry implementation.
class Sample(Bot): def __init__(self): Bot.__init__(self, '1m', 10) def options(self): return {} def strategy(self, open, close, high, low): lot = self.exchange.get_lot() which = random.randrange(2) if which == 0: self.exchange.entry("Long", True, lot) else: self.exchange.entry("Short", False, lot)
If you specify the strategy class name with the --strategy argument as shown below, you can run the bot with the added strategy.
$ python main.py --strategy Sample
if you support to me, please send BTC to me.
wallet: 1GPjM5AkdBDJnCouQ9AcS4mhUhdysXYCW1