Giter Site home page Giter Site logo

gekko-buyatsellat's Introduction

gekko-buyatsellat

Simple strategy to buy and sell assets at pre-defined thresholds with Gekko

This is a simple strategy which I have created in order to work with Gekko Trading bot

If you like the strategy, please feel free to donate some BTC to 1M7QRQ79h4ujQMMfbqk72QnXmRdwpyLVXn

This strategy can be configured to do below things -

  1. It should sell when the price surges to x% of the bought price, i.e. profit limit.
  2. It should sell when the price drops below y% of the bought price, i.e. stop loss.
  3. It should buy again if the price surges to z% of the sold price.
  4. It should buy again if the price goes down to u% of the sold price.

If you want to run Gekko via command line

You will need to change below 4 variables in buyatsellat.js as per your need -

const buyat = 1.05; // profit limit percentage (e.g. 1.15 for 15%)
const sellat = 0.97; // amount of percentage from last buy if market goes down (e.g. 0.97 for 3%)
const stop_loss_pct = 0.95; // stop loss percentage (e.g. 0.95 for 5%)
const sellat_up = 1.01; // amount of percentage from last buy if market goes up (e.g. 1.01 for 1%)

Copy the strategy file to /gekko/strategies folder.

Also, you will need to make below changes in config.js - In config.tradingAdvisor module, put buyatsellat as method, just like -

config.tradingAdvisor = {
enabled: true, 
method: 'buyatsellat', 
candleSize: 60, 
historySize: 2,

You can use any candle size you want. They are in Minutes.

After these changes, you can run Gekko by executing - node gekko --config config.js

If you want to run Gekko in UI mode

Copy buyatsellat_ui.js file to /gekko/strategies folder. Copy buyatsellat_ui.toml file to /gekko/config/strategies folder. (This file is used to change parameters in UI mode)

Run Gekko in UI mode by executing - node gekko --ui

Do let me know of any issues.

gekko-buyatsellat's People

Contributors

pushkarnagle 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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gekko-buyatsellat's Issues

A simple stop loss question

Hi!

What is the suggested usage of the buyatsellat strategy, or anyother strategy to serve as a simple stop loss?

Thanks in advance!

Which Config.js

There are 2 config.js files, which do we use?
gekko-stable\node_modules\chai\lib\chai\config.js
gekko-stable\node_modules\winston\lib\winston\config.js

Just thought it would be helpful to specify which :)

Buy and Sell % from CURRENT price

Hi,

I found your strategy in hopes of doing the following:

a) buy at 90% of the current price
b) sell for a +5% gain.

this way I can profit from "the dips" in price.

Can I do that with this strategy?

It seems I can only set percentages from bought/sold prices, not current prices...

A quick reply would be greatly appreciated! :)

Additional Profit Limit after series of multiple re-buys if the market price goes up

First of all i like this strategy but i would like to request if possible you can add something that we can maximize the profit when the price goes up to the moon.

Since we have an option for the next buy if the market price goes up, I would suggest that if you can also have an option for selling at another profit percentage if the price will still continue go higher and higher.

For example after 3-5 times buying at a higher price of the last sold price, i think we have to set a bigger profit percentage this time like 20-50% because this is an indication that the price will go up to 100% or more.

Of course if the price will go down before reaching the desired profit, we will sell it with the sell loss percentage.

Thank you

Unable to use data from other files, regarding two strategies

I've integrated the script into gekko:
https://github.com/pushkarnagle/gekko-buyatsellat
And right now I'm trying to run it together with strategies/rsi.js

Not really expecting a result yet, but I'm encoutering some issues.

First of all, I was able to import the buyatsellat.js script into RSI.js
Now I want to use some of the data in this script in the RSI.js script, but my lack of knowledge prohibits me from doing so.

I was wondering if you could help/teach me how to use variables, or cont's or other things from two scripts with each other?

Kind Regards!

Trailing stop loss

Hey. A trailing stop would be handy.
Put highest price since buy as a variable and apply the stop loss to that price instead of the buy price.
I need to learn coding urgently....

Not able to configure this strategy, I might be missing something?

Dear,

I've followed all the steps for setting up this bot, but I came across the following issue:
https://i.gyazo.com/0fb9fb34242d553f9d5167d4565bc13a.png

I made the strategy and added it to the strategies folder.

Now when I copy sample-config.js, and rename it to config.js and then replace this code:
https://i.gyazo.com/590f1f3feb91accdd1f1f218ce859464.png

I receive the error, I know that I'm doing something wrong, but I can't seem to figure out what.

I hope you can help!
thanks in advance!

all time same result

Hi I´m trying make a combination de GA + buyatsellat.
I find strange behavior, all time I have the same result.

Version of gekko v0.5.8

if you see the log all time I have de same maxprofit, also I´m try from de GUI and the behavior's the same

Epoch number: 40
Time it took (seconds): 5.907
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 67,

buyat: '2.94',
sellat: '1.16',
stop_loss_pct: '0.22',
sellat_up: '0.46',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.5246362407465106,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 67,

buyat: '2.94',
sellat: '1.16',
stop_loss_pct: '0.22',
sellat_up: '0.46',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.5246362407465106,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 41
Time it took (seconds): 5.197
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 83,

buyat: '2.94',
sellat: '1.16',
stop_loss_pct: '0.22',
sellat_up: '0.46',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7794555827678242,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 83,

buyat: '2.94',
sellat: '1.16',
stop_loss_pct: '0.22',
sellat_up: '0.46',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7794555827678242,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 42
Time it took (seconds): 6.814
Max profit: 937.6467540740005 $ max profit position: 1
Max parametars:
 { historySize: 60,

buyat: '1.33',
sellat: '1.23',
stop_loss_pct: '0.85',
sellat_up: '0.48',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6992839920927189,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 60,

buyat: '1.33',
sellat: '1.23',
stop_loss_pct: '0.85',
sellat_up: '0.48',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6992839920927189,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 43
Time it took (seconds): 6.838
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 100,

buyat: '0.34',
sellat: '1.12',
stop_loss_pct: '0.87',
sellat_up: '0.48',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6756025411826777,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 100,

buyat: '0.34',
sellat: '1.12',
stop_loss_pct: '0.87',
sellat_up: '0.48',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6756025411826777,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 44
Time it took (seconds): 5.569
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 53,

buyat: '0.34',
sellat: '1.12',
stop_loss_pct: '0.87',
sellat_up: '0.48',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.33843417442137513,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 53,

buyat: '0.34',
sellat: '1.12',
stop_loss_pct: '0.87',
sellat_up: '0.48',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.33843417442137513,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 45
Time it took (seconds): 4.863
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 37,

buyat: '0.34',
sellat: '1.12',
stop_loss_pct: '0.87',
sellat_up: '0.48',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7224112520627066,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 37,

buyat: '0.34',
sellat: '1.12',
stop_loss_pct: '0.87',
sellat_up: '0.48',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7224112520627066,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 46
Time it took (seconds): 5.01
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 69,

buyat: '0.34',
sellat: '1.12',
stop_loss_pct: '0.87',
sellat_up: '0.68',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.4704172299204544,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 69,

buyat: '0.34',
sellat: '1.12',
stop_loss_pct: '0.87',
sellat_up: '0.68',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.4704172299204544,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 47
Time it took (seconds): 6.524
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 70,

buyat: '0.34',
sellat: '1.12',
stop_loss_pct: '0.87',
sellat_up: '0.72',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6090449541493718,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 70,

buyat: '0.34',
sellat: '1.12',
stop_loss_pct: '0.87',
sellat_up: '0.72',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6090449541493718,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 48
Time it took (seconds): 5.605
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 65,

buyat: '0.34',
sellat: '1.04',
stop_loss_pct: '0.45',
sellat_up: '0.68',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6626813741569535,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 65,

buyat: '0.34',
sellat: '1.04',
stop_loss_pct: '0.45',
sellat_up: '0.68',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6626813741569535,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 49
Time it took (seconds): 6.465
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 21,

buyat: '1.50',
sellat: '1.18',
stop_loss_pct: '0.42',
sellat_up: '0.73',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.3576277509611333,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 21,

buyat: '1.50',
sellat: '1.18',
stop_loss_pct: '0.42',
sellat_up: '0.73',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.3576277509611333,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 50
Time it took (seconds): 5.526
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 21,

buyat: '1.50',
sellat: '1.18',
stop_loss_pct: '0.42',
sellat_up: '0.68',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6713432029605785,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 21,

buyat: '1.50',
sellat: '1.18',
stop_loss_pct: '0.42',
sellat_up: '0.68',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6713432029605785,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 51
Time it took (seconds): 5.67
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 58,

buyat: '0.34',
sellat: '1.04',
stop_loss_pct: '0.45',
sellat_up: '0.68',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6833153154301286,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 58,

buyat: '0.34',
sellat: '1.04',
stop_loss_pct: '0.45',
sellat_up: '0.68',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6833153154301286,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 52
Time it took (seconds): 5.542
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 40,

buyat: '1.50',
sellat: '1.18',
stop_loss_pct: '0.42',
sellat_up: '0.73',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7737833284575105,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 40,

buyat: '1.50',
sellat: '1.18',
stop_loss_pct: '0.42',
sellat_up: '0.73',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7737833284575105,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 53
Time it took (seconds): 6.491
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 89,

buyat: '0.34',
sellat: '1.18',
stop_loss_pct: '0.42',
sellat_up: '0.73',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6325692643148644,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 89,

buyat: '0.34',
sellat: '1.18',
stop_loss_pct: '0.42',
sellat_up: '0.73',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6325692643148644,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 54
Time it took (seconds): 5.254
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 32,

buyat: '1.50',
sellat: '1.04',
stop_loss_pct: '0.45',
sellat_up: '0.68',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.45010611344110574,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 32,

buyat: '1.50',
sellat: '1.04',
stop_loss_pct: '0.45',
sellat_up: '0.68',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.45010611344110574,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 55
Time it took (seconds): 4.811
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 47,

buyat: '0.34',
sellat: '1.18',
stop_loss_pct: '0.42',
sellat_up: '0.73',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.5936080000728406,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 47,

buyat: '0.34',
sellat: '1.18',
stop_loss_pct: '0.42',
sellat_up: '0.73',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.5936080000728406,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 56
Time it took (seconds): 5.896
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 50,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.84',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.35120354761982,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 50,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.84',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.35120354761982,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 57
Time it took (seconds): 5.171
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 58,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.84',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7711444245360582,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 58,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.84',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7711444245360582,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 58
Time it took (seconds): 6.942
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 72,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.84',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6254756271298368,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 72,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.84',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6254756271298368,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 59
Time it took (seconds): 4.941
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 83,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.84',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7696382265206366,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 83,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.84',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7696382265206366,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 60
Time it took (seconds): 6.416
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 81,

buyat: '2.22',
sellat: '1.10',
stop_loss_pct: '0.27',
sellat_up: '0.76',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6614208957827092,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 81,

buyat: '2.22',
sellat: '1.10',
stop_loss_pct: '0.27',
sellat_up: '0.76',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6614208957827092,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 61
Time it took (seconds): 5.572
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 81,

buyat: '2.22',
sellat: '1.10',
stop_loss_pct: '0.27',
sellat_up: '0.84',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7553533301614366,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 81,

buyat: '2.22',
sellat: '1.10',
stop_loss_pct: '0.27',
sellat_up: '0.84',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7553533301614366,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 62
Time it took (seconds): 5.006
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 34,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7138541819812834,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 34,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7138541819812834,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 63
Time it took (seconds): 6.618
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 81,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7305135543373136,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 81,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.7305135543373136,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 64
Time it took (seconds): 5.63
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 67,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.8195060414308304,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 67,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.8195060414308304,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 65
Time it took (seconds): 5.435
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 79,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.364076477187937,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 79,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.364076477187937,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 66
Time it took (seconds): 5.363
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 64,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6290748136239623,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 64,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6290748136239623,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 67
Time it took (seconds): 4.921
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 49,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.3726247283246683,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 49,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.3726247283246683,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 68
Time it took (seconds): 5.809
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 91,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.3605130010594074,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 91,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.3605130010594074,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 69
Time it took (seconds): 5.122
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 34,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6899585602061478,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 34,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.6899585602061478,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 70
Time it took (seconds): 7.686
Max profit: 937.6467540740005 $ max profit position: 1
Max parametars:
 { historySize: 81,

buyat: '2.44',
sellat: '1.07',
stop_loss_pct: '0.49',
sellat_up: '0.53',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.3820877027020362,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 81,

buyat: '2.44',
sellat: '1.07',
stop_loss_pct: '0.49',
sellat_up: '0.53',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.3820877027020362,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 71
Time it took (seconds): 5.494
Max profit: 937.6467540740005 $ max profit position: 1
Max parametars:
 { historySize: 88,

buyat: '2.44',
sellat: '1.07',
stop_loss_pct: '0.49',
sellat_up: '0.53',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.42557004389697983,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 88,

buyat: '2.44',
sellat: '1.07',
stop_loss_pct: '0.49',
sellat_up: '0.53',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.42557004389697983,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 72
Time it took (seconds): 5.3
Max profit: 259.9717331920001 $ max profit position: 0
Max parametars:
 { historySize: 96,

buyat: '2.98',
sellat: '1.28',
stop_loss_pct: '0.55',
sellat_up: '0.76',
candleSize: 60 }
Other metrics:
{ balance: 3000.971733192,
profit: 259.9717331920001,
sharpe: -0.36312446621890365,
market: 58.67883211678833,
relativeProfit: 9.484557942064953,
yearlyProfit: '1209.45982780',
relativeYearlyProfit: '44.12476570',
startPrice: 2740,
endPrice: 4347.8,
trades: 85 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 88,

buyat: '2.44',
sellat: '1.07',
stop_loss_pct: '0.49',
sellat_up: '0.53',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.42557004389697983,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 73
Time it took (seconds): 7.157
Max profit: 259.9717331920001 $ max profit position: 0
Max parametars:
 { historySize: 63,

buyat: '2.75',
sellat: '1.47',
stop_loss_pct: '0.45',
sellat_up: '0.22',
candleSize: 60 }
Other metrics:
{ balance: 3000.971733192,
profit: 259.9717331920001,
sharpe: -0.20808456203917836,
market: 58.67883211678833,
relativeProfit: 9.484557942064953,
yearlyProfit: '1209.45982780',
relativeYearlyProfit: '44.12476570',
startPrice: 2740,
endPrice: 4347.8,
trades: 85 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 88,

buyat: '2.44',
sellat: '1.07',
stop_loss_pct: '0.49',
sellat_up: '0.53',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.42557004389697983,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 74
Time it took (seconds): 8.294
Max profit: 259.9717331920001 $ max profit position: 2
Max parametars:
 { historySize: 86,

buyat: '2.76',
sellat: '1.08',
stop_loss_pct: '0.93',
sellat_up: '0.59',
candleSize: 60 }
Other metrics:
{ balance: 3000.971733192,
profit: 259.9717331920001,
sharpe: -0.42422023591272917,
market: 58.67883211678833,
relativeProfit: 9.484557942064953,
yearlyProfit: '1209.45982780',
relativeYearlyProfit: '44.12476570',
startPrice: 2740,
endPrice: 4347.8,
trades: 85 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 88,

buyat: '2.44',
sellat: '1.07',
stop_loss_pct: '0.49',
sellat_up: '0.53',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.42557004389697983,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 75
Time it took (seconds): 8.754
Max profit: 0 $ max profit position: 0
Max parametars:
 { historySize: 77,

buyat: '2.46',
sellat: '1.03',
stop_loss_pct: '0.31',
sellat_up: '0.85',
candleSize: 15 }
Other metrics:
{ balance: 2463.9406945279998,
profit: -277.05930547200023,
sharpe: -0.747910379330343,
market: 58.67883211678833,
relativeProfit: -10.107964446260496,
yearlyProfit: '-1288.95590214',
relativeYearlyProfit: '-47.02502379',
startPrice: 2740,
endPrice: 4347.8,
trades: 105 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 88,

buyat: '2.44',
sellat: '1.07',
stop_loss_pct: '0.49',
sellat_up: '0.53',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.42557004389697983,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 76
Time it took (seconds): 9.289
Max profit: 937.6467540740005 $ max profit position: 3
Max parametars:
 { historySize: 94,

buyat: '2.23',
sellat: '1.46',
stop_loss_pct: '0.29',
sellat_up: '1.00',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.721549228967853,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 94,

buyat: '2.23',
sellat: '1.46',
stop_loss_pct: '0.29',
sellat_up: '1.00',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.721549228967853,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 77
Time it took (seconds): 8.32
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 24,

buyat: '2.23',
sellat: '1.46',
stop_loss_pct: '0.29',
sellat_up: '1.00',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.708456778202172,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 24,

buyat: '2.23',
sellat: '1.46',
stop_loss_pct: '0.29',
sellat_up: '1.00',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.708456778202172,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

--------------------------------------------------------------
Epoch number: 78
Time it took (seconds): 6.463
Max profit: 937.6467540740005 $ max profit position: 0
Max parametars:
 { historySize: 55,

buyat: '2.23',
sellat: '1.46',
stop_loss_pct: '0.29',
sellat_up: '1.00',
candleSize: 240 }
Other metrics:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.5681996941919125,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }

--------------------------------------------------------------
Global maximum: 937.6467540740005 $, parameters:
 { historySize: 55,

buyat: '2.23',
sellat: '1.46',
stop_loss_pct: '0.29',
sellat_up: '1.00',
candleSize: 240 }
Other metrics of global maximum:
Global maximum so far:
{ balance: 3678.6467540740005,
profit: 937.6467540740005,
sharpe: 0.5681996941919125,
market: 58.67883211678833,
relativeProfit: 34.20819971083549,
yearlyProfit: '4362.18994965',
relativeYearlyProfit: '159.14593030',
startPrice: 2740,
endPrice: 4347.8,
trades: 69 }
--------------------------------------------------------------

Buy at current price and sell with profit

Hi,

I am trying to setup your strategy via command line. What I want to accomplish is this.

Get 100% of btc amount, buy coin at current market price and sell when a % happens.

Is this possible with your strategy?

Thanks!

Hold if making a loss

Is there a way to stop the selling action if you are going to make a loss? Or let me put it in a better way. Is there a way to sell ONLY when the price is greater than the sell_at property?. Sometimes it may take a long time i know but is it possible. It may help me more in understanding strategies for gekko. I tried removing the stop_loss but still i found some sells below the buying price for some reason. @pushkarnagle

TypeError: Cannot read property 'balance' of undefined

Hi,

I'm trying to run this strat from UI and I'm getting this error message in terminal.

TypeError: Cannot read property 'balance' of undefined

I checked the js file and I don't see a reference to 'balance'. Not sure why this error is popping up.

Cannot read property 'buyat' of undefined

i run this strat at UI mode and end up with error

D:\gekko-stable\node_modules\sqlite3\lib\trace.js:27
throw err;
^

TypeError: Cannot read property 'buyat' of undefined
at Base.method.check (D:\gekko-stable\gekko\strategies\buysellat_ui.js:31:26
)
at Base.bound [as check] (D:\gekko-stable\node_modules\lodash\dist\lodash.js
:729:21)
at Base.propogateTick (D:\gekko-stable\gekko\plugins\tradingAdvisor\baseTrad
ingMethod.js:243:10)
at Base.bound [as propogateTick] (D:\gekko-stable\node_modules\lodash\dist\l
odash.js:729:21)
at Base.tick (D:\gekko-stable\gekko\plugins\tradingAdvisor\baseTradingMethod
.js:153:10)
at Base.bound [as tick] (D:\gekko-stable\node_modules\lodash\dist\lodash.js:
729:21)
at Actor.processCustomCandle (D:\gekko-stable\gekko\plugins\tradingAdvisor\t
radingAdvisor.js:82:15)
at CandleBatcher.bound (D:\gekko-stable\node_modules\lodash\dist\lodash.js:7
29:21)
at emitOne (events.js:116:13)
at CandleBatcher.emit (events.js:211:7)
--> in Database#all('\n SELECT * from candles_USDT_BTC\n WHERE start <= 15
01595459 AND start >= 1501592460\n ORDER BY start ASC\n ', [Function])
at Reader.get (D:\gekko-stable\gekko\plugins\sqlite\reader.js:98:11)
at Reader.bound [as get] (D:\gekko-stable\node_modules\lodash\dist\lodash.js
:729:21)
at Market.get (D:\gekko-stable\gekko\core\markets\backtest.js:61:15)
at Market.bound [as get] (D:\gekko-stable\node_modules\lodash\dist\lodash.js
:729:21)
at Market.processCandles (D:\gekko-stable\gekko\core\markets\backtest.js:105
:10)
at bound (D:\gekko-stable\node_modules\lodash\dist\lodash.js:729:21)
at Statement. (D:\gekko-stable\gekko\plugins\sqlite\reader.js:108
:5)
xxx POST /api/backtest 500 868ms -

Error: non-error thrown: Child process has died.
at Object.onerror (D:\gekko-stable\node_modules\koa\lib\context.js:105:40)

  at <anonymous>
  at process._tickCallback (internal/process/next_tick.js:188:7)

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.