Record Class ExecutionAlgoBacktester.Config
java.lang.Object
java.lang.Record
com.quantfinlib.backtest.ExecutionAlgoBacktester.Config
- Record Components:
spreadBps- assumed quoted spread in bps of the close (bars carry no quotes) — the spread input the executor damps onparticipationCap- per-bar fill cap as a fraction of bar volume, in (0, 1]costModel- all-in one-way cost per fill (seeTradeCostModel)
- Enclosing class:
ExecutionAlgoBacktester
public static record ExecutionAlgoBacktester.Config(double spreadBps, double participationCap, TradeCostModel costModel)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionConfig(double spreadBps, double participationCap, TradeCostModel costModel) Creates an instance of aConfigrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecostModelrecord component.defaults()5 bps spread, 10% participation, flat 1 bp cost.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.doubleReturns the value of theparticipationCaprecord component.doubleReturns the value of thespreadBpsrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Config
Creates an instance of aConfigrecord class.- Parameters:
spreadBps- the value for thespreadBpsrecord componentparticipationCap- the value for theparticipationCaprecord componentcostModel- the value for thecostModelrecord component
-
-
Method Details
-
defaults
5 bps spread, 10% participation, flat 1 bp cost. -
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
spreadBps
-
participationCap
public double participationCap()Returns the value of theparticipationCaprecord component.- Returns:
- the value of the
participationCaprecord component
-
costModel
-