Documentation ¶
Index ¶
Constants ¶
View Source
const ( //CandleClose - CandleClose = iota //CandleOpen - CandleOpen //CandleHigh - CandleHigh //CandleLow - CandleLow //CandleTime - CandleTime )
View Source
const ( //SMA - SMA = iota //EMA - EMA //WMA - WMA //DEMA - DEMA //TEMA - TEMA //TRIMA - TRIMA //KAMA - KAMA //MAMA - MAMA )
View Source
const ( //Call - Call = iota + 1 //Put - Put //Neutral - Neutral )
Variables ¶
View Source
var CandleData = []Candle{ Candle{ID: 1, Name: "1 Second"}, Candle{ID: 5, Name: "5 Second"}, Candle{ID: 10, Name: "10 Second"}, Candle{ID: 15, Name: "15 Second"}, Candle{ID: 30, Name: "30 Second"}, Candle{ID: 60, Name: "1 Minute"}, Candle{ID: 120, Name: "2 Minute"}, Candle{ID: 300, Name: "5 Minute"}, }
CandleData -
View Source
var MovingAverageData = []MovingAverage{ MovingAverage{ID: 0, Short: "SMA", Name: "Simple Moving Average"}, MovingAverage{ID: 1, Short: "EMA", Name: "Exponential Moving Average"}, MovingAverage{ID: 2, Short: "WMA", Name: "Weighted Moving Average"}, MovingAverage{ID: 3, Short: "DEMA", Name: "Double Exponential Moving Average"}, MovingAverage{ID: 4, Short: "TEMA", Name: "Triple Exponential Moving Average"}, MovingAverage{ID: 5, Short: "TRIMA", Name: "Triangular Moving Average"}, MovingAverage{ID: 6, Short: "KAMA", Name: "Kaufman Adaptive Moving Average"}, MovingAverage{ID: 7, Short: "MAMA", Name: "MESA Adaptive Moving Average"}, }
MovingAverageData -
View Source
var SourceData = []Source{ Source{ID: CandleClose, Name: "Close"}, Source{ID: CandleOpen, Name: "Open"}, Source{ID: CandleHigh, Name: "High"}, Source{ID: CandleLow, Name: "Low"}, }
SourceData -
Functions ¶
func CreateHash ¶
CreateHash -
Types ¶
type Group ¶
type Group struct { ID string `json:"id"` StrategyID string `json:"strategyId"` Name string `json:"name"` Enable bool `json:"enable"` Default bool `json:"default"` Created time.Time `json:"created"` Trigger int `json:"trigger"` }
Group -
type Indicator ¶
type Indicator struct { Hash string `json:"hash"` ID string `json:"id"` GroupID string `json:"groupId"` Name string `json:"name"` Options map[string]interface{} `json:"options"` Trigger map[int]string `json:"trigger"` Active bool `json:"active"` }
Indicator -
type Result ¶
type Result struct { Time time.Time `json:"time"` Value map[string]interface{} `json:"value"` Trigger map[string]map[int]bool `json:"trigger"` TimeCalculation time.Duration `json:"timeCalculation"` }
Result -
Click to show internal directories.
Click to hide internal directories.