Class ParentOrder
java.lang.Object
com.quantfinlib.backtest.ParentOrder
One parent order worked by the
ExecutionAwareBacktester: the signal
that created it, the arrival price (close at signal time — the TCA
benchmark), and the child fills with the bar index each filled on.
reason is "ENTRY" for entries, or the exit reason
(signal / STOP_LOSS / TAKE_PROFIT / END_OF_DATA).-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionParentOrder(Side side, int signalIndex, double arrivalPrice, String reason, List<Execution> fills, int[] fillBarIndices) Creates the value; array and collection arguments are copied. -
Method Summary
Modifier and TypeMethodDescriptiondoublearrivalPrice.doublebooleanintfillBarIndices(int i) ElementioffillBarIndices.int[]A fresh copy offillBarIndices.intLength offillBarIndices.intBars from first to last fill (0 for unfilled or single-bar parents).longfills()fills.inthashCode()reason()reason.side()side.intsignalIndex.toString()
-
Field Details
-
REASON_ENTRY
- See Also:
-
-
Constructor Details
-
ParentOrder
-
-
Method Details
-
side
side. -
signalIndex
public int signalIndex()signalIndex. -
arrivalPrice
public double arrivalPrice()arrivalPrice. -
reason
reason. -
fills
-
fillBarIndices
public int fillBarIndices(int i) ElementioffillBarIndices. -
fillBarIndicesLength
public int fillBarIndicesLength()Length offillBarIndices. -
fillBarIndicesCopy
public int[] fillBarIndicesCopy()A fresh copy offillBarIndices. -
filledQty
public long filledQty() -
avgFillPrice
public double avgFillPrice() -
fillDurationBars
public int fillDurationBars()Bars from first to last fill (0 for unfilled or single-bar parents). -
equals
-
hashCode
-
toString
-