Welcome, Guest |
You have to register before you can post on our site.
|
Online Users |
There are currently 339 online users. » 0 Member(s) | 339 Guest(s)
|
Latest Threads |
Gekko 0.6 released
Forum: Announcements
Last Post: lsm99dna
Yesterday, 08:15 PM
» Replies: 124
» Views: 332,151
|
An official Gekko service...
Forum: Announcements
Last Post: Ruslanjoshua
07-24-2025, 06:27 AM
» Replies: 111
» Views: 246,519
|
New Gekko UI in the works
Forum: Announcements
Last Post: celemtine
07-03-2025, 07:24 AM
» Replies: 185
» Views: 323,398
|
Gekko with malware spotte...
Forum: Announcements
Last Post: pugoing
07-01-2025, 02:29 AM
» Replies: 212
» Views: 274,825
|
Gekko development status ...
Forum: Announcements
Last Post: sanmarconns
10-21-2024, 06:34 PM
» Replies: 744
» Views: 1,466,436
|
How to add Binance Future...
Forum: Technical Support
Last Post: Xavier32
10-07-2021, 02:20 PM
» Replies: 47
» Views: 133,897
|
Bittrex Configuration hel...
Forum: Bittrex
Last Post: yirzolusto
10-07-2021, 07:39 AM
» Replies: 6
» Views: 22,866
|
[Question] Why does gekko...
Forum: General Discussion
Last Post: cryptocurrency0
10-06-2021, 01:16 PM
» Replies: 16
» Views: 57,107
|
a couple of technical Que...
Forum: Technical Support
Last Post: mtom78632
10-06-2021, 11:08 AM
» Replies: 25
» Views: 71,741
|
crex24
Forum: Other exchanges
Last Post: marketingseo
10-05-2021, 09:47 AM
» Replies: 216
» Views: 511,688
|
|
|
Profits only in longer duration Candles |
Posted by: altamash - 11-19-2018, 03:15 PM - Forum: Strategy Development
- Replies (3)
|
 |
I am new to crypto bots.
Thank you guys for your contribution towards this forum. It helped me a lot.
Coming to the point.
I manually backtested hundreds of strategies with different time frames for the past 8 months data (I couldn't get the GA to work)
Most of the strategies available built-in or custom (available on GitHub) with default parameters yielded losses in this bear market in one hour or 15 minutes candles.
But if I configure Candle size to 10 hours or more, then strategies like DEMA, MACD, neuralnet return positive results but with only few trades . As 10 hour candle size leads to longer exposure (in days) i feel it implies more risk.
I couldn't find a strategy which would perform in a bear market with smaller candlesize say 5 min or 1 min so gekko can do more frequent low risk/profit trades.
Am I missing anything? Would appreciate any pointers or leads
|
|
|
Beginner's question |
Posted by: pdbc - 11-15-2018, 02:44 PM - Forum: General Discussion
- Replies (2)
|
 |
Hi everybody.
Just joined this community. I would like to start coding my own strategy on this framework, I'm coming from a deeply modified-by-me version of Zenbot, but before going in deep with this new framework, I need to know if with Gekko I can overpass limits which I have with Zenbot. I hope someone of you experts can spend a little bit of time for a rookie like me.
Here my questions:
1) Is it possible to open different positions? In the meaning of: can I set a buy order, let it to be executed, store all the details in an object and then, if needed, set again a new buy order, let it to be executed and [...], so opening different long positions, till some conditions trigger the "sell" order for a certain position?
Example:
Time= 1000
buy trigger -> buy order -> bought 1 BTC at 5000€ -> store details in positions[1]
Time= 2000
buy trigger -> buy order -> bought 1 BTC at 4900€ -> store details in positions[2]
Time= 3000
buy trigger -> buy order -> bought 1 BTC at 5100€ -> store details in positions[3]
Time= 4000
sell trigger -> sell order for positions[2] at 5200€/BTC -> delete positions[2]
(With Zenbot it was not possible, it buys and sells a percentage of the total capital, so I had to deeply modify the engine to succed this)
2) Is it possible to open simultaneous order, and follow them one by one?
Example:
Time= 1000
buy trigger -> buy order at fixed price 4900€/BTC (order[1]) -> waiting for order[1] to be settled...
Time= 2000
buy trigger -> buy order at fixed price 4800€/BTC (order[2]) -> waiting for order[2] to be settled...
Time= 3000
price is 4900€/BTC -> order[1] settled -> store details in positions[1]
Time= 4000
sell trigger -> sent order for positions[1] at fixed price 5200€/BTC (order[3]) -> waiting for order[3] to be settled...
Time= 5000
price is 4800€/BTC -> order[2] settled -> store details in positions[2]
...and so on.
(With Zenbot, this is not possible. I should deeply modify the code, but I prefer to switch to a different platform before taking up this real asspain)
-------
That's all! Pretty easy to answer if you are acquainted with the code, but not for me if I have to read all the sources.
As said, it is not a matter of coding again my strategy, I will do this in a pretty fair time, but a matter of having an underlying framework which will support me and does not costrain me to modify everything in deep!
If something is not clear, please ask me and I will answer all of your questions. I really would like to leave Zenbot framework, cause till now it was a never-ending modifying job to tailor it to my needs.
Thanks to all!
|
|
|
Plugins |
Posted by: Kris191 - 11-12-2018, 06:00 AM - Forum: General Discussion
- Replies (4)
|
 |
Hello,
Quick one, can plugins be enabled if using UI? if so how? i cannot seem to find a config files to edit what plugins i want to run.
Thanks
|
|
|
Log Indicates Portfolio Balance Incorrectly |
Posted by: TonyAnthony - 11-11-2018, 01:14 AM - Forum: Binance
- Replies (4)
|
 |
I was attempting to trade ETC/BAT.
Once the Bot starts and pulls from Binance, my ETH Balance is at first correct and then after the Balance part reports incorrect.
This causes the bot to no trade in the proper direction. Is this a Binance API issue? It has only happened for this pair so far.
Portfolio:
2018-11-10 19:40:03 (INFO): 0.00003129 ETH
2018-11-10 19:40:03 (INFO): 0.945 BAT
2018-11-10 19:40:03 (INFO): Balance:
2018-11-10 19:40:03 (INFO): 0.00127023225 ETH
2018-11-10 19:40:03 (INFO): Exposed:
2018-11-10 19:40:03 (INFO): yes (97.54%)
|
|
|
Indicators visualization on backtests |
Posted by: thaal - 11-10-2018, 03:04 PM - Forum: Strategy Development
- No Replies
|
 |
I'm still pretty new, so forgive me if I missed something.
I'm trying to define settings on strategies based on vvarious indicators however, I like the visual data on backtests graphs to see the triggers and adjust accordingly... Of course i can try adjusting some numbers and try to run the backtest again but that's a bit counter productive...
Or is there a way to backtest with tones of different settings at once in order to find optimal settings ?
Also I found out sometimes back tests results can be quite different from the actual real world trade bot performance, even when matching strategies and fees during live trading with the backtest run afterwards on the same past period ^^
|
|
|
Failed to load indicator Alligator |
Posted by: noba - 11-08-2018, 10:12 PM - Forum: Technical Discussion
- Replies (1)
|
 |
Hello all,
I tried to from the command line with this node gekko -c config.js and i get this error:
Code: 2018-11-09 00:08:30 (ERROR): Failed to load indicator Alligator
2018-11-09 00:08:30 (ERROR): Failed to load indicator HEIKEN
2018-11-09 00:08:31 (ERROR): Failed to load indicator PIVOTHIGHLOW
2018-11-09 00:08:31 (ERROR): Failed to load indicator RSI-beta
I check and i have on the strategies/indicators that js files. How i can fix that ?
|
|
|
Fee and roundtrip profit report calculations. Are they correct? |
Posted by: slav - 11-08-2018, 06:54 PM - Forum: Technical Discussion
- Replies (3)
|
 |
So I was recently doing some backtesting, and noticed that the single roundtrip profit report (gekko ui by the way) is a bit deceiving, at least to me.
It's not really that big of a problem but rases some questions.
At times it will show that during roundtrip I made a profit when in reality I made a loss.
Let me show you what I mean on a example:
My initial balance is 10000 currency no asset. fee is 0.1% (both maker and taker)
After the first roundtrip I get a report:
entry balance = 9990, exit balance = 9999, p&l = 9, profit = 0.09%
So report shows a profit of 9 currency, but when we look at the exit balance it's clearly a loss of 1 currency.
It calculates the profit based on "entry balance" which is the previous (in this case initial) balance after fee. this gives us 9990 currency.
Wouldn't it be better if it was based on previous roundtrip exit balance, so it would show a 1 currency loss instead of a profit?
Next I found the calculation in performance analyzer to be done like this:
Code: roundtrip.pnl = roundtrip.exitBalance - roundtrip.entryBalance;
I then determined how the entry balance is calculated:
Code: this.roundTrip.entry = {
date: trade.date,
price: trade.price,
total: trade.portfolio.currency + (trade.portfolio.asset * trade.price), // <--- here
}
Code: PerformanceAnalyzer.prototype.handleCompletedRoundtrip = function() {
var roundtrip = {
id: this.roundTrip.id,
entryAt: this.roundTrip.entry.date,
entryPrice: this.roundTrip.entry.price,
entryBalance: this.roundTrip.entry.total,// <--- and further here
exitAt: this.roundTrip.exit.date,
exitPrice: this.roundTrip.exit.price,
exitBalance: this.roundTrip.exit.total,
duration: this.roundTrip.exit.date.diff(this.roundTrip.entry.date)
}
Everything seems fine so far, but let's check out how trade.portfolio.asset is being calculated(assuming it's being fetched straight from paperTrader.js?):
Code: if(what === 'long') {
cost = (1 - this.fee) * this.portfolio.currency;
this.portfolio.asset += this.extractFee(this.portfolio.currency / this.price);// <------------------- here
amount = this.portfolio.asset;
this.portfolio.currency = 0;
this.exposed = true;
this.trades++;
}
where the extractFee() function does this:
Code: PaperTrader.prototype.extractFee = function(amount) {
amount *= 1e8; // <------------------------------------- (10000 currency / price like 15.7175) 636.2334976936536 * 10^8 = 63623349769.36536
amount *= this.fee;//<----------------------------------- 63623349769.36536 * 0.999 = 63559726419.59599
amount = Math.floor(amount);//<--------------------------- Rounds down removing everything after the comma so we get 63559726419
amount /= 1e8; // <----------------------------------------63559726419 / 10^8 = 635.59726419
return amount;
}
I get 635.59726419 of asset so now paperTrader uses this number to calculate the balance we have and here is where it gets interesting:
Code: PaperTrader.prototype.getBalance = function() {
return this.portfolio.currency + this.price * this.portfolio.asset;
}
When calculated returns : 0 + 15.7175 * 635.59726419 = 9989.999999906326 !?
Well that should be equal 9990 right?
Because the extractFee() function uses Math.floor() we lose that .59599 which changes the final result giving us a slightly incorrect balance.
I understand it's limiting the amount of numbers after the comma for the exchange.
So my question is how does this affect the whole bot? Does it have an effect at all?
How does it affect real trading?
It's a bit concerning that maybe this problem could compound on itself overtime affecting the final result of backtest/live trade.
|
|
|
|