pricer

package
v1.63.0 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2025 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CoveredDepth

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

func NewCoveredDepth

func NewCoveredDepth(depthBook *types.DepthBook, side types.SideType, initialDepth fixedpoint.Value) *CoveredDepth

func (*CoveredDepth) Cover

func (d *CoveredDepth) Cover(depth fixedpoint.Value)

func (*CoveredDepth) Pricer

func (d *CoveredDepth) Pricer() Pricer

type Pricer

type Pricer func(i int, price fixedpoint.Value) fixedpoint.Value

func AdjustByTick

func AdjustByTick(side types.SideType, pips, tickSize fixedpoint.Value) Pricer

func ApplyFeeRate

func ApplyFeeRate(side types.SideType, feeRate fixedpoint.Value) Pricer

func ApplyMargin

func ApplyMargin(side types.SideType, margin fixedpoint.Value) Pricer

func Compose

func Compose(pricers ...Pricer) Pricer

func FromBestPrice

func FromBestPrice(side types.SideType, book *types.StreamOrderBook) Pricer

func FromDepthBook

func FromDepthBook(side types.SideType, depthBook *types.DepthBook, depth fixedpoint.Value) Pricer

Jump to

Keyboard shortcuts

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