Gekko Forum
Plot data points - Printable Version

+- Gekko Forum (https://forum.gekko.wizb.it)
+-- Forum: Gekko (https://forum.gekko.wizb.it/forum-13.html)
+--- Forum: Feature Requests (https://forum.gekko.wizb.it/forum-15.html)
+--- Thread: Plot data points (/thread-1434.html)



Plot data points - tommiehansen - 02-04-2018

Ability to plot data from a/the strategy.

Use something similar to TradingView's pinescript, pseudo code:

Code:
var strat = {

    init: function()
    {
        this.name = 'Hello world';
        
        this.addTulipIndicator('maSlow', 'tema', { optInTimePeriod: this.settings.long });
        this.addTulipIndicator('maFast', 'sma', { optInTimePeriod: this.settings.short });
        this.addTulipIndicator('myRSI', 'rsi', { optInTimePeriod: this.settings.RSI });
        
        this.plot(
            { data: 'maSlow', color: 'black', width: 2, overlay: true },
            { data: 'maFast', color: '#f00', width: 1, overlay: true },
            { data: 'myRSI', overlay: false }
        );
    }

};


Params

- data
- color (named/hex)
- line width (in px)
- overlay (overlay the data or add it under the graph)


RE: Plot data points - askmike - 02-05-2018

Hey! There were some ideas in the past. Though I don't think strategies need to define what they want to plot: we can simply plot all indicators results automatically since Gekko is aware about them already. See here for a start: https://github.com/askmike/gekko/pull/793

Note that that PR won't be finished soon, it makes a lot more sense to add this functionality to the completely new UI we will build Smile


RE: Plot data points - tommiehansen - 02-08-2018

Yes, i read that after posting this thread ofc. Smile

I agree that you shouldn't use HighCharts, especially since there are free alternatives such as the Google Visualization library etc.