strategy

package
v0.0.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 11, 2021 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Controller

type Controller struct {
	// contains filtered or unexported fields
}

func NewStrategyController

func NewStrategyController(pair string, settings model.Settings, strategy Strategy,
	broker exchange.Broker) *Controller

func (*Controller) OnCandle

func (s *Controller) OnCandle(candle model.Candle)

func (*Controller) Start

func (s *Controller) Start()

type Strategy

type Strategy interface {
	Init(settings model.Settings)
	Timeframe() string
	WarmupPeriod() int
	Indicators(dataframe *model.Dataframe)
	OnCandle(dataframe *model.Dataframe, broker exchange.Broker)
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL