movingstats

package module
v0.0.0-...-5dfabb7 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2017 License: Apache-2.0 Imports: 8 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

movingaverage

Moving Average for Trading

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HighLow

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

func NewHighLow

func NewHighLow(size int) *HighLow

func (*HighLow) SortedInsert

func (hl *HighLow) SortedInsert(pf PriFloat)

func (*HighLow) SortedSlice

func (hl *HighLow) SortedSlice() []PriFloat

type MovingAverage

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

func NewAverage

func NewAverage(period int) *MovingAverage

func (*MovingAverage) Add

func (avg *MovingAverage) Add(value float64)

func (*MovingAverage) MovingStandardDeviation

func (avg *MovingAverage) MovingStandardDeviation() float64

func (*MovingAverage) SimpleMovingAverage

func (avg *MovingAverage) SimpleMovingAverage() float64

type MovingStats

type MovingStats struct {
	HistMostRecent float64
	HistOldest     float64
	HistNow        float64
	// contains filtered or unexported fields
}

func NewMovingStats

func NewMovingStats(size int) *MovingStats

func (*MovingStats) Add

func (ms *MovingStats) Add(value float64)

func (*MovingStats) Adx

func (ms *MovingStats) Adx() float64

func (*MovingStats) Atr

func (ms *MovingStats) Atr() float64

func (*MovingStats) CHigh

func (ms *MovingStats) CHigh() float64

func (*MovingStats) CLow

func (ms *MovingStats) CLow() float64

func (*MovingStats) CurrentHigh

func (ms *MovingStats) CurrentHigh() float64

func (*MovingStats) CurrentLow

func (ms *MovingStats) CurrentLow() float64

func (*MovingStats) DoubleEma

func (ms *MovingStats) DoubleEma() float64

func (*MovingStats) DoubleEmaSlope

func (ms *MovingStats) DoubleEmaSlope() float64

func (*MovingStats) DoubleEmaUp

func (ms *MovingStats) DoubleEmaUp() bool

func (*MovingStats) Ema1

func (ms *MovingStats) Ema1() float64

func (*MovingStats) Ema1Slope

func (ms *MovingStats) Ema1Slope() float64

func (*MovingStats) Ema1Up

func (ms *MovingStats) Ema1Up() bool

func (*MovingStats) EmaMacd9

func (ms *MovingStats) EmaMacd9() float64

func (*MovingStats) Macd

func (ms *MovingStats) Macd() float64

func (*MovingStats) MacdDiv

func (ms *MovingStats) MacdDiv() float64

func (*MovingStats) MinusDI

func (ms *MovingStats) MinusDI() float64

func (*MovingStats) MinusDM

func (ms *MovingStats) MinusDM() float64

func (*MovingStats) PHigh

func (ms *MovingStats) PHigh() float64

func (*MovingStats) PLow

func (ms *MovingStats) PLow() float64

func (*MovingStats) PlusDI

func (ms *MovingStats) PlusDI() float64

func (*MovingStats) PlusDM

func (ms *MovingStats) PlusDM() float64

func (*MovingStats) PreviousClose

func (ms *MovingStats) PreviousClose() float64

func (*MovingStats) SMA1

func (ms *MovingStats) SMA1() float64

func (*MovingStats) StdDev1

func (ms *MovingStats) StdDev1() float64

func (*MovingStats) StdDevLong

func (ms *MovingStats) StdDevLong() float64

func (*MovingStats) TripleEma

func (ms *MovingStats) TripleEma() float64

func (*MovingStats) TripleEmaSlope

func (ms *MovingStats) TripleEmaSlope() float64

func (*MovingStats) TripleEmaUp

func (ms *MovingStats) TripleEmaUp() bool

func (*MovingStats) TrueRange

func (ms *MovingStats) TrueRange() float64

type PriFloat

type PriFloat struct {
	Data float64
	Age  int
}

func (*PriFloat) Less

func (fp *PriFloat) Less(f PriFloat) bool

Jump to

Keyboard shortcuts

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