Giter Club home page Giter Club logo

gekko's Introduction

This repo is not maintained anymore

I am officially not maintaining this project anymore. It was an amazing journey and I want to thank everyone for playing the role in this amazing story!

More details can be found here: https://medium.com/@gekkoplus/archiving-open-source-gekko-dba02e6efc7

This only impacts my Gekko repo (askmike/gekko). There might be other forks of Gekko out there that are being maintained!


Old content:


Gekko npm Build Status Build status

Gordon Gekko

The most valuable commodity I know of is information.

-Gordon Gekko

Gekko is a Bitcoin TA trading and backtesting platform that connects to popular Bitcoin exchanges. It is written in JavaScript and runs on Node.js.

Use Gekko at your own risk.

Documentation

See the documentation website.

Installation & Usage

See the installing Gekko doc.

Community & Support

Gekko has a forum that is the place for discussions on using Gekko, automated trading and exchanges. In case you rather want to chat in realtime about Gekko feel free to join the Gekko Support Discord.

Final

If Gekko helped you in any way, you can always leave me a tip at (BTC) 13r1jyivitShUiv9FJvjLH7Nh1ZZptumwW

gekko's People

Contributors

arcxyz avatar askmike avatar bmarchesini avatar cmroche avatar dankhuu avatar deke997 avatar deviavir avatar djmuk avatar generalectric avatar greenbigfrog avatar hiyan avatar iceydee avatar imperator6 avatar jjongman avatar julesgoullee avatar kevtherev13 avatar krieghof avatar milianx avatar mkondel avatar nevrending avatar oktapodia avatar paulovms avatar ratkor avatar s7evink avatar streetlogics avatar vivekmarakana avatar werkkrew avatar xfffff avatar xhad avatar yin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gekko's Issues

Not trading and price difference == NaN

I think my instance of gekko isn't working with BTCe. I have an account configured, and Gekko uses a 4h 10/21 EMA for trading, it shows this every 4h:
2013-07-19 12:33:26 (INFO): ADVICE is to HOLD @ 83.839 (NaN)
Notice the NaN there. The price changes of course. The reason I think it's not working is that it didn't sell since 2013-07-17, ignoring the price drop yesterday.

gekko sometimes failed with error on btc-e

Error: 502
at Request._callback (/home/alexxy/Src/gekko/node_modules/bitcoincharts/bitcoincharts.js:34:23)
at Request.self.callback (/home/alexxy/Src/gekko/node_modules/bitcoincharts/node_modules/request/index.js:142:22)
at Request.EventEmitter.emit (events.js:98:17)
at Request. (/home/alexxy/Src/gekko/node_modules/bitcoincharts/node_modules/request/index.js:856:14)
at Request.EventEmitter.emit (events.js:117:20)
at IncomingMessage. (/home/alexxy/Src/gekko/node_modules/bitcoincharts/node_modules/request/index.js:808:12)
at IncomingMessage.EventEmitter.emit (events.js:117:20)
at _stream_readable.js:910:16
at process._tickCallback (node.js:415:13)

Wrong balance reporting with new profit tool

2013-06-02 23:19:59 (INFO): trading at BTC-E ACTIVE
2013-06-02 23:19:59 (INFO): BTC-E trading fee will be: 0.2%
2013-06-02 23:19:59 (INFO): current BTC-E portfolio:
2013-06-02 23:19:59 (INFO): USD: 6.8e-7
2013-06-02 23:19:59 (INFO): RUR: 0.00000923
2013-06-02 23:19:59 (INFO): EUR: 0
2013-06-02 23:19:59 (INFO): BTC: 0.15447517
2013-06-02 23:19:59 (INFO): LTC: 0
2013-06-02 23:19:59 (INFO): NMC: 0
2013-06-02 23:19:59 (INFO): NVC: 0
2013-06-02 23:19:59 (INFO): TRC: 0
2013-06-02 23:19:59 (INFO): PPC: 0
2013-06-02 23:19:59 (INFO): FTC: 0
2013-06-02 23:19:59 (INFO): CNC: 0
2013-06-02 23:19:59 (INFO): Calculating EMA on historical data...
2013-06-02 23:19:59 (INFO): ADVICE is to HOLD @ 121.409 (0.054)
2013-06-02 23:21:59 (INFO): refreshing
2013-06-02 23:21:59 (INFO): ADVICE is to HOLD @ 121.241 (0.018)
2013-06-02 23:21:59 (INFO): (PROFIT REPORT) original balance: 221.409 USD
2013-06-02 23:21:59 (INFO): (PROFIT REPORT) current balance: 221.241 USD
2013-06-02 23:21:59 (INFO): (PROFIT REPORT) profit: -0.168 USD (-0.076%)
2013-06-02 23:23:59 (INFO): refreshing
2013-06-02 23:23:59 (INFO): ADVICE is to HOLD @ 121.410 (0.004)
2013-06-02 23:23:59 (INFO): (PROFIT REPORT) original balance: 221.409 USD
2013-06-02 23:23:59 (INFO): (PROFIT REPORT) current balance: 221.410 USD
2013-06-02 23:23:59 (INFO): (PROFIT REPORT) profit: 0.001 USD (0.000%)

LTC trading @ BTC-e

I've tried to use gakko to trade litecoins on at btc-e. I've set the exchange to 'BTCe', asset to 'LTC' in the config.normal and in config.watch sections, and when I start gekko it shows me "ADVICE is to HOLD @ 101.300 (NaN)", which is the price of of btc/usd on BTCe.

[mtgox] Advice Log - wrong Currency?

I am getting the following info log

2013-05-29 02:00:10 (INFO): ADVICE is to HOLD @ 128.990 (-0.140)

My config.js has the following values:

config.watch = {
exchange: 'MtGox',
currency: 'EUR',
asset: 'BTC'
}
...
config.traders = [
{
exchange: 'MtGox',
...
currency: 'EUR', // You probably want this the same as in the watcher
asset: 'BTC',
enabled: true
},

The advice value looks more like the current USD value rather than the EUR value I set in the config.

Gekko can't pull GHS balance from cex.io

Trying to get Gekko to auto trade but it seems to be a problem when it tries to get the GHS balance from cex.io and thous it can't sell GHS.

BTC saldo and buying works though...

When starting:
2013-12-04 14:23:07 (INFO): Using normal settings to monitor the live market
2013-12-04 14:23:07 (INFO): Profit reporter active on simulated balance
2013-12-04 14:23:07 (DEBUG): getting balance & fee from cex.io
2013-12-04 14:23:13 (INFO): trading at cex.io ACTIVE
2013-12-04 14:23:13 (INFO): cex.io trading fee will be: 0%
2013-12-04 14:23:13 (INFO): current cex.io portfolio:
2013-12-04 14:23:13 (INFO): BTC: 0.00000145
2013-12-04 14:23:13 (INFO): GHS: NaN
2013-12-04 14:23:13 (INFO): Calculating EMA on historical data...
2013-12-04 14:23:13 (DEBUG): fetching historical data at cex.io

When trying to sell
2013-12-04 12:26:13 (DEBUG): we are currently in a downtrend @ 0.07277501 (-0.007)
2013-12-04 12:26:13 (INFO): ADVICE is to SELL @ 0.07277501 (-0.007)
2013-12-04 12:26:13 (INFO): wanted to sell but insufficient GHS (NaN) at cex.io
2013-12-04 12:27:10 (DEBUG): fetching new trades for new bucket at cex.io
2013-12-04 12:27:12 (DEBUG): cex.io fetching from tid 543256
2013-12-04 12:27:12 (DEBUG): fetching since 1386156422

Best regards,
N

Error/Crash with default config

TypeError: Cannot call method 'toFixed' of undefined
at TradingMethod.advice (/home/kliberty/gekko/methods/exponential-moving-averages.js:130:42)
at TradingMethod.calculateEMAs (/home/kliberty/gekko/methods/exponential-moving-averages.js:95:10)
at EventEmitter.emit (events.js:92:17)
at CandleCalculator.calculateCandle (/home/kliberty/gekko/methods/realtime-candle-fetcher.js:177:8)
at CandleCalculator.fillNewBucket (/home/kliberty/gekko/methods/realtime-candle-fetcher.js:163:8)
at null. (/home/kliberty/gekko/exchanges/mtgox.js:56:7)
at Request._callback (/home/kliberty/gekko/node_modules/mtgox-apiv2/mtgox.js:48:11)
at Request.self.callback (/home/kliberty/gekko/node_modules/mtgox-apiv2/node_modules/request/index.js:148:22)
at Request.EventEmitter.emit (events.js:98:17)
at Request. (/home/kliberty/gekko/node_modules/mtgox-apiv2/node_modules/request/index.js:876:14)

[Explanation] simulationBalance in config.js

Hi,

just a short question about the following:

// start balance, on what the current balance is compared with
simulationBalance: {
// these are in the unit types configured in the watcher.
asset: 1,
currency: 100,
},

Could you please briefly explain what exactly those values mean.

Installation Error

OS: Windows 8.1 Pro
-Command Prompt ran as Admin

NodeJS: v0.10.22
-This issue appears in both 32bit and 64bit installs of NodeJS.

Issue:
--I also copied the path where 'npm install' was invoked. As you can see it was in the right directory.

e:\Software\BitCoin\Bots\gekko-master>npm install
npm http GET https://registry.npmjs.org/mtgox-apiv2
npm http GET https://registry.npmjs.org/btc-e
npm http GET https://registry.npmjs.org/bitcoincharts
npm http GET https://registry.npmjs.org/moment
npm http GET https://registry.npmjs.org/prompt-lite
npm http GET https://registry.npmjs.org/bitstamp/0.0.4
npm http GET https://registry.npmjs.org/lodash
npm http GET https://registry.npmjs.org/line-reader
npm http GET https://registry.npmjs.org/async
npm ERR! not found: git
npm ERR!
npm ERR! Failed using git.
npm ERR! This is most likely not a problem with npm itself.
npm ERR! Please check if you have git installed and in your PATH.

npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\Program Files\nodejs\node.exe" "C:\Program Files\nod
ejs\node_modules\npm\bin\npm-cli.js" "install"
npm ERR! cwd e:\Software\BitCoin\Bots\gekko-master
npm ERR! node -v v0.10.22
npm ERR! npm -v 1.3.14
npm ERR! code ENOGIT
npm http 304 https://registry.npmjs.org/bitcoincharts
npm http 304 https://registry.npmjs.org/btc-e
npm http 304 https://registry.npmjs.org/prompt-lite
npm http 304 https://registry.npmjs.org/moment
npm http 304 https://registry.npmjs.org/mtgox-apiv2
npm http 304 https://registry.npmjs.org/bitstamp/0.0.4
npm http 304 https://registry.npmjs.org/lodash
npm http 304 https://registry.npmjs.org/line-reader
npm http 304 https://registry.npmjs.org/async
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! e:\Software\BitCoin\Bots\gekko-master\npm-debug.log
npm ERR! not ok code 0

Gekko shows advice only once

Hi!

I've tried to run Gekko, and it shown message about calculation and then advice, but then it stuck and showd nothing during the all night. Is it the issue or there are no messages when you shouldn't do anything?

Also, how often Gekko asks MTGoc about new information?

error with install.

npm install
npm http GET https://registry.npmjs.org/mtgox-apiv2
npm http GET https://registry.npmjs.org/lodash
npm http GET https://registry.npmjs.org/moment
npm http GET https://registry.npmjs.org/btc-e
npm http GET https://registry.npmjs.org/bitcoincharts
npm http GET https://registry.npmjs.org/prompt-lite
npm http GET https://registry.npmjs.org/bitstamp/0.0.4
npm http GET https://registry.npmjs.org/async
npm http GET https://registry.npmjs.org/line-reader
npm http 200 https://registry.npmjs.org/btc-e

npm ERR! Error: No compatible version found: btc-e@'>=0.0.0- <0.1.0-'
npm ERR! No valid targets found.
npm ERR! Perhaps not compatible with your version of node?
npm ERR! at installTargetsError (/usr/share/npm/lib/cache.js:488:10)
npm ERR! at next_ (/usr/share/npm/lib/cache.js:438:17)
npm ERR! at next (/usr/share/npm/lib/cache.js:415:44)
npm ERR! at /usr/share/npm/lib/cache.js:408:5
npm ERR! at saved (/usr/share/npm/lib/utils/npm-registry-client/get.js:147:7)
npm ERR! at Object.oncomplete (/usr/lib/nodejs/graceful-fs.js:230:7)
npm ERR! You may report this log at:
npm ERR! http://bugs.debian.org/npm
npm ERR! or use
npm ERR! reportbug --attach /home/gekko/npm-debug.log npm
npm ERR!
npm ERR! System Linux 3.0.60-odroidu2
npm ERR! command "node" "/usr/bin/npm" "install"
npm ERR! cwd /home/gekko
npm ERR! node -v v0.6.12
npm ERR! npm -v 1.1.4
npm ERR! message No compatible version found: btc-e@'>=0.0.0- <0.1.0-'
npm ERR! message No valid targets found.
npm ERR! message Perhaps not compatible with your version of node?
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/gekko/npm-debug.log
npm not ok

Cannot read property 'order_id' of undefined

2013-10-26 17:22:06 (DEBUG): getting balance & fee from BTC-E
2013-10-26 17:22:07 (INFO): trading at BTC-E ACTIVE
2013-10-26 17:22:07 (INFO): BTC-E trading fee will be: 0.2%
2013-10-26 17:22:07 (INFO): current BTC-E portfolio:
2013-10-26 17:22:07 (INFO): USD: 0.00000175
2013-10-26 17:22:07 (INFO): BTC: 0.66583663

...

2013-10-26 17:23:41 (DEBUG): calculated candle: 0
2013-10-26 17:23:41 (DEBUG): calced EMA properties for new candle:
2013-10-26 17:23:41 (DEBUG): short ema 190.679
2013-10-26 17:23:41 (DEBUG): long ema 191.549
2013-10-26 17:23:41 (DEBUG): diff ema -0.455
2013-10-26 17:23:41 (DEBUG): we are currently in a downtrend @ 188.065 (-0.455)
2013-10-26 17:23:41 (INFO): ADVICE is to SELL @ 188.065 (-0.455)
2013-10-26 17:23:41 (INFO): attempting to SELL BTC at BTC-E
2013-10-26 17:23:43 (INFO): Send advice via email.
2013-10-26 17:23:43 (ERROR): unable to sell: [Error: It is not enough BTC in the account for sale.]

TypeError: Cannot read property 'order_id' of undefined
at set (/home/joy/mining/gekko/exchanges/btce.js:50:23)
at bound (/home/joy/mining/gekko/node_modules/lodash/dist/lodash.js:1318:23)
at Request._callback (/home/joy/mining/gekko/node_modules/btc-e/btc-e.js:52:16)
at Request.self.callback (/home/joy/mining/gekko/node_modules/btc-e/node_modules/request/index.js:142:22)
at Request.EventEmitter.emit (events.js:98:17)
at Request. (/home/joy/mining/gekko/node_modules/btc-e/node_modules/request/index.js:856:14)
at Request.EventEmitter.emit (events.js:117:20)
at IncomingMessage. (/home/joy/mining/gekko/node_modules/btc-e/node_modules/request/index.js:808:12)
at IncomingMessage.EventEmitter.emit (events.js:117:20)
at _stream_readable.js:910:16

Failed to load historical trades from Bitstamp

Just to let you know that when getting trades from BS Gekko always quits with the message above.

I tried to understand whats going on, but I was unable to figure it out from the code.

Inaccurate trend estimate, fixed on restart

I left gekko running for a few days, and it continued to report an uptrend despite the fact that the market was in an obvious downtrend. I restarted gekko, and only then did it start to accurately report that there was a downtrend. Specifically, when I restarted it it was reporting +1.091, and afterwards it reported -0.274. Unfortunately I don't have any debug information to go along with this.

Trading Fees

Is it possible to add a variable to config.traders sections per exchanger that sets the trading fee so that it could be taken into account as well?

Incorrect balance in simulation mode ?

Hello,
My problem is that I set simulation balance to asset=1 and currency=0 with trading BTC/USD on BTC-e but the fisrt advice is to BUY asset.
I have tried to set another values in the config file but the first advice is always to buy asset.
Can you help me to find the problem ?
(Sorry for my english I am french with "scolar english")

BTC-e stuck on 'Calculating EMA on historical data...'

When setting Gekko to pull data from BTCe nothing is actually being pulled from anywhere and Gekko seems to be stuck on Calculating EMA on historical data...

When enabling debug mode:

2013-11-28 12:50:29 (DEBUG):    fetching historical data at bitcoincharts
2013-11-28 12:50:29 (DEBUG):    bitcoincharts returned an error, retrying..

(And just as a side note: Would BTC/LTC trading on BTC-e be a possibility with Gekko?)

[Helpful Addition] Colored Advice

Seeing a white wall of text can be...hard to read. So here's a nice change.

You'll need to install 'colors' first in NodeJS (npm install colors)

in the 'exponential-moving-averages.js'

Add this to under '// helpers':
'var colors = require('colors');'

Now go to here 'Buy', 'Sell', 'Hold' are located (do a word search).

and change them to:
'this.emit('advice', 'BUY'.green, price, message);'
'this.emit('advice', 'HOLD'.yellow, price, message);'
'this.emit('advice', 'SELL'.red, price, message);'

FOR EVER INSTANCE OF BUY, SELL, HOLD

PS: Not sure where 'improvements' go, Askmike, so I posted here :)

toFixed method undefined

TypeError: Cannot call method 'toFixed' of undefined
at TradingMethod.advice (/home/alexxy/Src/gekko/methods/exponential-moving-averages.js:112:42)
at TradingMethod.calculateEMAs (/home/alexxy/Src/gekko/methods/exponential-moving-averages.js:77:10)
at EventEmitter.emit (events.js:92:17)
at CandleCalculator.calculateCandle (/home/alexxy/Src/gekko/methods/candle-method.js:152:8)
at CandleCalculator.fillNewBucket (/home/alexxy/Src/gekko/methods/candle-method.js:138:8)
at /home/alexxy/Src/gekko/exchanges/bitcoincharts.js:43:7
at Request._callback (/home/alexxy/Src/gekko/node_modules/bitcoincharts/bitcoincharts.js:48:5)
at Request.self.callback (/home/alexxy/Src/gekko/node_modules/bitcoincharts/node_modules/request/index.js:142:22)
at Request.EventEmitter.emit (events.js:98:17)
at Request. (/home/alexxy/Src/gekko/node_modules/bitcoincharts/node_modules/request/index.js:856:14)

[mtgox] Server responded with an error or no data, sleeping.

Hi,

  • I have the latest version (last pull around 1 day ago ~25.05.2013)
  • My mtgox account is setup to trade with EUR. (your mtgox config doesnt seem to have a currency switch like btce)
  • API Key has "Get Info" and "Trade" Permissions
  • I enabled real trading for mtgox and received the following error

2013-05-26 13:49:49 (INFO): ADVICE is to BUY @ 133.590 (0.379)
2013-05-26 13:49:49 (INFO): (PROFIT REPORT) -0.000% profit (in 1 trades)
2013-05-26 13:49:49 (ERROR): Server responded with an error or no data, sleeping.
2013-05-26 13:50:49 (DEBUG): fetching exchange...
2013-05-26 13:50:53 (DEBUG): fetched exchange
2013-05-26 13:50:53 (DEBUG): calculated new tick: -1 price: 133.590 diff: 0.427
2013-05-26 13:50:53 (ERROR): Server responded with an error or no data, sleeping.
2013-05-26 13:51:53 (DEBUG): fetching exchange...
2013-05-26 13:51:53 (ERROR): Server responded with an error or no data, sleeping.
2013-05-26 13:52:53 (DEBUG): fetching exchange...
2013-05-26 13:52:54 (ERROR): Server responded with an error or no data, sleeping.

My config is as follows:

var config = {};

config.tradingMethod =  'Exponential Moving Averages';
config.watch =  {
  exchange: 'MtGox',
}
config.EMA = {
  interval: 60,
  shortEMA: 10,
  longEMA: 21,
  ticks: 100,
  sampleSize: 10,
  sellTreshold: -0.25,
  buyTreshold: 0.25
};
config.traders = [
  {
    exchange: 'MtGox',
    key: 'my_key_is_here',
    secret: 'my_secret_is_here',
    enabled: true
  },
  {
    exchange: 'BTCe',
    key: '',
    secret: '',
    currency: 'USD',
    enabled: false
  },
  {
    exchange: 'Bitstamp',
    user: '',
    password: '',
    enabled: false
  }
];
config.profitCalculator = {
  enabled: true,
  reportInBTC: false,
  simulationBalance: {
    btc: 1,
    foreign: 100,
  }
}
config.mail = {
  enabled: false,
  email: '', 
  password: ''
}
config.debug = true;
module.exports = config;

Any idea what could be wrong?

New trading method - stop loss

Mike, correct me if I'm wrong, wouldn't it be quite simple to implement a stop-loss trading method in gekko? This would be useful in bubble territory :-) what do you think?

TypeError: Cannot read property 'statusCode' of undefined

$node gekko.js
2013-06-03 23:51:23 (INFO): I'm gonna make you rich, Bud Fox.
2013-06-03 23:51:23 (INFO): Let me show you some Exponential Moving Averages.
2013-06-03 23:51:23 (INFO): Profit reporter active on simulated balance
2013-06-03 23:51:23 (DEBUG): Setup email adviser.
2013-06-03 23:51:23 (DEBUG): getting balance & fee from Mt. Gox

TypeError: Cannot read property 'statusCode' of undefined
at Request._callback (/home/yak/gekko/node_modules/mtgox-apiv2/mtgox.js:47:16)
at self.callback (/home/yak/gekko/node_modules/mtgox-apiv2/node_modules/request/index.js:148:22)
at Request.EventEmitter.emit (events.js:97:17)
at ClientRequest.self.clientErrorHandler (/home/yak/gekko/node_modules/mtgox-apiv2/node_modules/request/index.js:257:10)
at ClientRequest.EventEmitter.emit (events.js:97:17)
at CleartextStream.socketErrorListener (_http_client.js:211:9)
at CleartextStream.EventEmitter.emit (events.js:97:17)
at Socket.onerror (tls.js:1368:17)
at Socket.EventEmitter.emit (events.js:119:20)
at net.js:857:16

was working fine earlier and just recently did this

Recreate order on BTC-E failed

2013-06-02 21:06:27 (INFO): attempting to BUY BTC at BTC-E
2013-06-02 21:07:00 (INFO): BUY order was not (fully) filled, canceling and creating new order

TypeError: Object [object Object] has no method 'cancelOrder'
at finish (/home/alexxy/Src/gekko/portfolioManager.js:262:21)
at check (/home/alexxy/Src/gekko/exchanges/btce.js:115:7)
at Request._callback (/home/alexxy/Src/gekko/node_modules/btc-e/btc-e.js:55:7)
at Request.self.callback (/home/alexxy/Src/gekko/node_modules/btc-e/node_modules/request/index.js:142:22)
at Request.EventEmitter.emit (events.js:98:17)
at Request. (/home/alexxy/Src/gekko/node_modules/btc-e/node_modules/request/index.js:856:14)
at Request.EventEmitter.emit (events.js:117:20)
at IncomingMessage. (/home/alexxy/Src/gekko/node_modules/btc-e/node_modules/request/index.js:808:12)
at IncomingMessage.EventEmitter.emit (events.js:117:20)
at _stream_readable.js:910:16

Backtesting over 2013-05-23

I wanted to backtest agaist more recent data, but the provided candles go only up to 2013-05-23. So I tried to dump them myself, following your instructions here:
https://bitcointalk.org/index.php?topic=239815.0
After many hours of work it turns out that the dump tool also downloads only up to 2013-05-23. Do you know the reason for this? Is there a way to go up to today?

Freeze

The bot seems to freeze immediately after giving the advice.

2013-06-21 12:29:06 (DEBUG): we are currently not in an up or down trend @ 81.605 (0.007)
2013-06-21 12:29:06 (INFO): ADVICE is to HOLD @ 81.605 (0.007)

Waited multiple hours, tested with different configs.

Exchanges Reference Issue

I'm getting reference issue with 'this' in exchanger class...

Output:

    if (err) throw err;
                   ^
TypeError: Cannot call method 'add' of undefined
    at EventEmitter.trader.trade (/Users/username/gekko/exchanges/mtgox.js:21:16)
    at EventEmitter.emit (events.js:117:20)
    at advice (/Users/username/gekko/methods/exponential-moving-averages.js:198:22)
    at /Users/username/gekko/methods/exponential-moving-averages.js:84:5
    at IncomingMessage.<anonymous> (/Users/username/gekko/node_modules/mtgox-apiv2/mtgox.js:42:13)
    at IncomingMessage.EventEmitter.emit (events.js:117:20)
    at _stream_readable.js:883:14
    at process._tickCallback (node.js:415:13)

and the same will happen on sale...

Node Version:

v0.10.3

error at bitcoincharts

today i'was clone the project the first time. here is the output.

2013-10-12 17:08:30 (INFO): Calculating EMA on historical data...
2013-10-12 17:08:30 (DEBUG): fetching historical data at bitcoincharts
2013-10-12 17:08:48 (DEBUG): bitcoincharts returned an error, retrying..
2013-10-12 17:09:20 (DEBUG): bitcoincharts returned an error, retrying..
2013-10-12 17:09:53 (DEBUG): bitcoincharts returned an error, retrying..
2013-10-12 17:10:27 (DEBUG): bitcoincharts returned an error, retrying..
2013-10-12 17:10:57 (DEBUG): bitcoincharts returned an error, retrying..
2013-10-12 17:11:18 (DEBUG): bitcoincharts returned an error, retrying..

Having a error. Mind helping?

Currently I have an issue setting up the config to cex.io for ghs/btc trading. I've put in my api with all accesses to ensure it wasn't a api issue. Ive activated the api also.

The bot works fine when I disable real trading but when I enable it for real trading, I keep getting this error.

C:\Users\VC\Desktop\tradebot>node gekko
2013-12-03 22:21:27 (INFO): I'm gonna make you rich, Bud Fox.
2013-12-03 22:21:27 (INFO): Let me show you some Exponential Moving Averages
.

2013-12-03 22:21:27 (INFO): Using normal settings to monitor the live market

2013-12-03 22:21:27 (INFO): Profit reporter active on simulated balance

C:\Users\VC\Desktop\tradebot\exchanges\cexio.js:167
currency = parseFloat(data.BTC.available) - parseFloat(data.BTC.orders);
^
TypeError: Cannot read property 'available' of undefined
at calculate (C:\Users\VC\Desktop\tradebot\exchanges\cexio.js:167:35)
at bound (C:\Users\JVC\Desktop\tradebot\node_modules\lodash\dist\lodash.j
s:725:21)
at IncomingMessage. (C:\Users\VC\Desktop\tradebot\node_module
s\cexio\cexio.js:63:7)
at IncomingMessage.EventEmitter.emit (events.js:117:20)
at _stream_readable.js:920:16
at process._tickCallback (node.js:415:13)

C:\Users\VC\Desktop\tradebot>

What do these errors mean? Is it related to how I set up the real trading information? Or is this a api error related to gekko?

Windows: Couldn't read dependencies

C:\Users\User\Desktop\gekko-master>npm install
npm ERR! install Couldn't read dependencies
npm ERR! Error: ENOENT, open 'C:\Users\User\Desktop\gekko-master\package.json'

npm ERR! If you need help, you may report this log at:
npm ERR! http://github.com/isaacs/npm/issues
npm ERR! or email it to:
npm ERR! [email protected]

npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:\Program Files\nodejs\node.exe" "C:\Program Files\nod
ejs\node_modules\npm\bin\npm-cli.js" "install"
npm ERR! cwd C:\Users\User\Desktop\gekko-master
npm ERR! node -v v0.10.10
npm ERR! npm -v 1.2.25
npm ERR! path C:\Users\User\Desktop\gekko-master\package.json
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! C:\Users\User\Desktop\gekko-master\npm-debug.log
npm ERR! not ok code 0

The error log wasn't created.

My OS is Windows 7.

EMA *calculation* interval

A lot can happen in an hour. Just look at the drop on mtgox a few hours ago. I don't know much about EMAs, but wouldn't it help to do the calculations more often? I'm not talking about decreasing the timeframe of the candle, just redoing the calculations for the last 100 ticks every few minutes with every tick lasting 1h.

One other thing to consider - what is the safe interval to not get banned by mtgox for to many requests.

Or this could be pure nonsense ;)

Did bitcoincharts changed its API(s)?

When I try to run gekko for BTC-e, I got this confusing error:

Failed to load historical trades from bitcoincharts

After a lookup of the source code and compare to bitcoincharts' API (http://api.bitcoincharts.com/v1/trades.csv?symbol=btceUSD ), I discovered that bitcoincharts returns trade data ascending. But in gekko/exchanges/bitcoincharts.js, it is treated as descending:

    if(descending)
      callback(trades);
    else
      callback(trades.reverse());

Switch the callback parameter and my problem solved.

any integration with btc-china?

Thanks a ton for everything so far.

Curious if there are any plans to integrate support for the btc-china exchange?

I have some utilities in my fork for fetching data / backtesting btc-china (forgive me it's greasy).

Thanks

Freeze

The bot seems to freeze immediately after giving the advice.

2013-06-21 12:29:06 (DEBUG): we are currently not in an up or down trend @ 81.605 (0.007)
2013-06-21 12:29:06 (INFO): ADVICE is to HOLD @ 81.605 (0.007)

Waited multiple hours, tested with different configs.

If there is no data in new refresh period gekko got exception

2013-05-30 09:42:13 (INFO): ADVICE is to HOLD @ 126.971 (-0.054)
2013-05-30 09:42:13 (INFO): (PROFIT REPORT) 0.149% profit (in 0 trades)
2013-05-30 09:43:12 (INFO): refreshing
false { data:
[ { date: '1369892497',
price: '126.971000000000',
amount: '0.390000000000' },
{ date: '1369892497',
price: '126.971000000000',
amount: '1.013760000000' } ] }
2013-05-30 09:43:12 (INFO): ADVICE is to HOLD @ 126.971 (-0.056)
2013-05-30 09:43:12 (INFO): (PROFIT REPORT) 0.149% profit (in 0 trades)
2013-05-30 09:45:12 (INFO): refreshing
[Error: TypeError: Cannot call method 'slice' of undefined] undefined
2013-05-30 09:45:12 (ERROR): Server responded with an error or no data, sleeping.
2013-05-30 09:45:42 (INFO): refreshing

Mt. Gox trading fee will be: NaN%

Getting this error when trying to actual enable trader..

2013-11-19 15:10:25 (INFO): Using normal settings to monitor the live market
2013-11-19 15:10:25 (INFO): Profit reporter active on simulated balance
2013-11-19 15:10:28 (INFO): trading at Mt. Gox ACTIVE
2013-11-19 15:10:28 (INFO): Mt. Gox trading fee will be: NaN%
2013-11-19 15:10:28 (INFO): current Mt. Gox portfolio:
2013-11-19 15:10:28 (INFO): Calculating EMA on historical data...

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.