stats

package
v0.0.0-...-51932e9 Latest Latest
Warning

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

Go to latest
Published: May 23, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildAndSaveNormalizedPlot

func BuildAndSaveNormalizedPlot(cd []models.CandlesData) error

func BuildAndSavePercentagePlot

func BuildAndSavePercentagePlot(cd []models.CandlesData) error

func BuildAndSavePricePlot

func BuildAndSavePricePlot(cd []models.CandlesData) error

func BuildCorrelationMatrix

func BuildCorrelationMatrix(cd []models.CandlesData) [][]float64

func BuildSpreadPlot

func BuildSpreadPlot(x, y models.CandlesData) (spread []float64, time []int64)

func FindPearsonCorrelation

func FindPearsonCorrelation(x, y []float64) float64

func FindSellBuyPrices

func FindSellBuyPrices(data *sync.Map) *sync.Map

func SaveCorrelationPlot

func SaveCorrelationPlot(rs [][]float64, cd []models.CandlesData) error

func SaveTime

func SaveTime(cd []models.CandlesData, path string) error

func WriteCSV

func WriteCSV(cd []models.CandlesData, data [][]float64, t, filename string) error

Types

type SellBuy

type SellBuy struct {
	AvgPos float64 `json:"avgPos"`
	AvgNeg float64 `json:"avgNeg"`
}

type SpreadFile

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

func NewSpreadFile

func NewSpreadFile(path string) (*SpreadFile, error)

func (*SpreadFile) AddSpread

func (s *SpreadFile) AddSpread(spread []float64, time []int64, name string) error

func (*SpreadFile) SaveSpread

func (s *SpreadFile) SaveSpread() error

Jump to

Keyboard shortcuts

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