com.optstack.api.strategies

OrderFiltersT

abstract class OrderFiltersT[T] extends RankByTrait with SizeByTrait with AutoCompleteVisibility with Logging2

Linear Supertypes
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. OrderFiltersT
  2. Logging2
  3. AutoCompleteVisibility
  4. SizeByTrait
  5. RankByTrait
  6. AnyRef
  7. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new OrderFiltersT(minStrikePercent: Double = -0.3, maxStrikePercent: Double = 0.3, isSameExpirationForAllLegs: Boolean = false, isSameStrikeForAllLegs: Boolean = false, isInDescendingStrikeOrder: Boolean = false, enableDefaultFilters: Boolean, parentPosition: <error>)(implicit scriptCtx: <error>)

Abstract Value Members

  1. abstract def createInitFunc(spreadQuantity: Int = 1, orderID: String = "", comments: String = "", shouldReverse: Boolean = false): (OrderT) ⇒ Boolean

    Attributes
    protected
  2. abstract def getOptionableLegs: Seq[<error>]

    Attributes
    protected
  3. abstract def getStrategyID(): String

  4. abstract def initGlobalScope(): Unit

    Attributes
    protected
  5. abstract def shouldReverseForBuy(): Boolean

    Attributes
    protected
  6. abstract def shouldReverseForSell(): Boolean

    Attributes
    protected

Concrete Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final val SET_INIT_FN: String("setInintFn")

    Attributes
    protected
  7. final var SET_INIT_FN2: String

    Attributes
    protected
  8. final def addCustomOrderFunction(orderFunc: (OrderT) ⇒ Boolean, name: String = ...): T

    Attributes
    protected
    Annotations
    @FunctionInfo()
  9. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  10. final def buy(): OrderFiltersT[T]

    Buy the specified spread.

    Buy the specified spread. To set the quantity, use the sizeBy () method

    var ndx = this.getSecurity("^NDX")
    val butterfly = ndx.strategies.butterflies.IronButterfly
    butterfly.buy().sizeBy.risk(targetRisk=10000)
    Annotations
    @FunctionInfo()
  11. final def buy(orderID: String, comments: String): OrderFiltersT[T]

    Buy the spread.

    Buy the spread. Specify an orderID in order to reference this position in the future. To set the quantity, use the sizeBy method.

    To reference position using the orderID, use the selectPosition() API.

    var ndx = this.getSecurity("^NDX")
    val butterfly = ndx.strategies.butterflies.IronButterfly
    butterfly.buy ("MyButterfly", "MyComments").sizeBy.risk(targetRisk=10000)
    
    this.selectPosition("MyButterfly");
    Annotations
    @FunctionInfo()
    See also

    StrategyRunnerT#selectPosition

  12. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  13. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  14. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  15. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  16. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  17. def getLegsInDescendingStrikeOrder: Seq[<error>]

    Attributes
    protected
  18. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  19. def initDefaultFilters(): Unit

    Attributes
    protected
  20. final def isBuyOrder(): Boolean

  21. var isInDescendingStrikeOrder: Boolean

    Attributes
    protected
  22. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  23. var isSameExpirationForAllLegs: Boolean

    Attributes
    protected
  24. var isSameStrikeForAllLegs: Boolean

    Attributes
    protected
  25. def logError(message: ⇒ Any): Unit

    Definition Classes
    Logging2
  26. var maxConcurrentPositions: Int

    Attributes
    protected
  27. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  28. final def notify(): Unit

    Definition Classes
    AnyRef
  29. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  30. implicit final val orderCriteria: <error>

    Attributes
    protected
  31. def println(logLevel: Int, message: ⇒ Any): Unit

    Definition Classes
    Logging2
  32. def println(message: ⇒ Any): Unit

    Definition Classes
    Logging2
  33. final def rankBy(): RankOrderT

    Rank all matching spreads by criteria such as cost, risk / reward, etc.

    Rank all matching spreads by criteria such as cost, risk / reward, etc..

    Definition Classes
    OrderFiltersTRankByTrait
    Annotations
    @FunctionInfo()
  34. final def rollFrom(pos: PosT, comments: String = "", doNotCloseParentPosition: Boolean = false): Unit

    Select the prior position to close.

    Select the prior position to close. Roll into this new position after prior position is closed. If prior position is already closed, no rolling will take place.

    Annotations
    @FunctionInfo()
  35. def selectBy(scaleByQuantity: Boolean): OrderFilterScopeT[T]

    Select the entire position in order to add specific criteria for overall position.

    Select the entire position in order to add specific criteria for overall position.

    Certain metrics will change based on the size of the position. For example, max risk / max reward / option greeks will scale up or down based on the size of the position.

    If you don't want these metrics to be affected by the size of the position, set "scaleByQuantity=false"

    If scaleByQuantity = false, metrics will be evaluated assuming quantity is 1.

    Otherwise, metrics will be evaluated based on full position size.

    Annotations
    @FunctionInfo()
  36. final def selectTopN(n: Int): RankByTrait

    Select the Top N matching spreads based on the "rankBy" criteria used.

    Select the Top N matching spreads based on the "rankBy" criteria used. Default is to select only the top (N=1)

    Annotations
    @FunctionInfo()
  37. final def sell(): OrderFiltersT[T]

    Sell the specified spread.

    Sell the specified spread. To set the quantity, use the sizeBy () method

    var ndx = this.getSecurity("^NDX")
    val butterfly = ndx.strategies.butterflies.IronButterfly
    butterfly.sell().sizeBy.risk(targetRisk=10000)
    Annotations
    @FunctionInfo()
  38. final def sell(orderID: String, comments: String): OrderFiltersT[T]

    Sell / short the spread.

    Sell / short the spread. Specify an orderID in order to reference this position in the future. To set the quantity, use the sizeBy method.

    To reference position using the orderID, use the selectPosition() API.

    var ndx = this.getSecurity("^NDX")
    val butterfly = ndx.strategies.butterflies.IronButterfly
    butterfly.sell ("MyButterfly", "MyComments").sizeBy.risk(targetRisk=10000)
    
    this.selectPosition("MyButterfly");
    Annotations
    @FunctionInfo()
    See also

    StrategyRunnerT#selectPosition

  39. final def setMaxOpenPositions(n: Int): Unit

    Set the maximum number of open positions of this particular type of order

    Set the maximum number of open positions of this particular type of order

    Annotations
    @FunctionInfo()
  40. final def sizeBy(): SizeByFilterT

    Size all matching spreads by cost, risk, margin, etc.

    Size all matching spreads by cost, risk, margin, etc..

    Definition Classes
    OrderFiltersTSizeByTrait
    Annotations
    @FunctionInfo()
  41. def submitOrder(orderID: String = "")(implicit scriptCtx: <error>): Unit

    Attributes
    protected
  42. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  43. def toString(): String

    Definition Classes
    AnyRef → Any
  44. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  45. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  46. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Deprecated Value Members

  1. final def buy(quantity: Int): OrderFiltersT[T]

    Buy the spread.

    Buy the spread. Quantity is ignored if specific "sizeBy" criteria are defined.

    Annotations
    @FunctionInfo() @deprecated
    Deprecated
  2. final def buy(quantity: Int, orderID: String = "", comments: String = ""): OrderFiltersT[T]

    Buy the spread.

    Buy the spread. Specify an orderID in order to reference this position in the future. Quantity is ignored if specific "sizeBy" criteria are defined.

    To reference position using the orderID, use the selectPosition() API.

    val cc = ndx.strategies.withStock.CoveredCall
    cc.buy(quantity=10,orderID="vertical1001",comments="Enter CoveredCall When 50 Day MVG crosses above 200 Day MVG")
    
    .....
    .....
    
    // select the covered call order using the orderID
    val coveredCall = this.selectPosition(orderID="vertical1001")
    Annotations
    @FunctionInfo() @deprecated
    Deprecated
    See also

    StrategyRunnerT#selectPosition

  3. def selectBy: OrderFilterScopeT[T]

    Select the entire position in order to add specific criteria for overall position.

    Select the entire position in order to add specific criteria for overall position.

    Certain metrics will change based on the size of the position. For example, max risk / max reward / option greeks will scale up or down based on the size of the position.

    By default, computation will be evaluated based on full position size.

    Annotations
    @FunctionInfo() @deprecated
    Deprecated
  4. final def sell(quantity: Int): OrderFiltersT[T]

    Sell / short the spread.

    Sell / short the spread. Quantity is ignored if specific "sizeBy" criteria are defined.

    Annotations
    @FunctionInfo() @deprecated
    Deprecated
  5. final def sell(quantity: Int, orderID: String = "", comments: String = ""): OrderFiltersT[T]

    Sell / short the spread.

    Sell / short the spread. Specify an orderID in order to reference this position in the future. Quantity is ignored if specific "sizeBy" criteria is defined.

    To reference position using the orderID, use the selectPosition() API.

    val cc = ndx.strategies.withStock.CoveredCall
    cc.sell(quantity=10,orderID="vertical1001",comments="Enter CoveredCall When 50 Day MVG crosses above 200 Day MVG")
    
    .....
    .....
    
    // select the covered call order using the orderID
    val coveredCall = this.selectPosition(orderID="vertical1001")
    Annotations
    @FunctionInfo() @deprecated
    Deprecated
    See also

    StrategyRunnerT#selectPosition

Inherited from Logging2

Inherited from AutoCompleteVisibility

Inherited from SizeByTrait

Inherited from RankByTrait

Inherited from AnyRef

Inherited from Any

Ungrouped