Click or drag to resize

Strategy Class

Base abstract class for trading strategy. Implements basic trading logic and position management.
Inheritance Hierarchy

Namespace:  MZpack.NT8.Algo
Assembly:  MZpack.NT8.Pro (in MZpack.NT8.Pro.dll) Version: 3.18.1.0 (3.18.1.0)
Syntax
C#
[SerializableAttribute]
public class Strategy : ViewModelBase

The Strategy type exposes the following members.

Constructors
  NameDescription
Public methodStrategy
Initializes a new instance of the Strategy class
Public methodCode exampleStrategy(String, MZpackStrategyBase)
Initializes a new instance of the Strategy class
Top
Properties
  NameDescription
Public propertyDashboard
Public propertyExitPattern
The exit pattern.
Public propertyLogLevel
Log level.
Public propertyLogTarget
Log target.
Public propertyLogTime
Add chart time to each log record.
Public propertyMZpackStrategy
Native NinjaTrader strategy.
Public propertyName
Name of the strategy.
Public propertyOppositePatternAction
How to manage opened position when pattern with opposite direction is validated.
Public propertyPattern
The entry pattern.
Public propertyPosition
Algorithmic position of the strategy.
Public propertyRiskManagement
Public propertySessionBreak
Reset the strategy and all signals on new session. Default is True. Opened position is still controled by Ninja settings.
Public propertyTradingTimes
Trading times. The strategy doesn't make entries outside trading times. Working orders outside trading times will be closed, pending orders will be canceled. TradingTimes doesn't affect on a strategy in Manual operating mode.
Top
Methods
  NameDescription
Public methodInitialize(Pattern, Entry, Int32)
Initializes algorithmic strategy.
Public methodInitialize(Pattern, Pattern, Entry, Int32)
Initializes algorithmic strategy.
Public methodIsTrade
Public methodLog
Logs the text depending on LogLevel property.
Public methodStatic memberLogFolderPath
Log folder path.
Public methodLogHeader
Public methodLogLF
Logs line feed.
Public methodLogNinjaScriptProperties
Logs public properties with NinjaScriptProperty attribute. LogLevel must contain LogLevel.PROPERTIES.
Public methodOnEntryPatternNotValidated
Public methodOnEntryPatternValidated
Public methodOnExitPatternValidated
Public methodOnOrderFilled
Override to implement custom behavore on native NinjaTrader order filling.
Public methodOnOrderUpdate
Override to implement custom behavore on native NinjaTrader order update. base.OnOrderUpdate() call required.
Public methodOnPositionOpenFilter
Override to implement filter before openig a position.
Public methodOnPositionUpdate
Override to implement custom behavore on native NinjaTrader position update. base.OnPositionUpdate() call required.
Public methodOnValidateEntryPatternFilter
Override to implement filter before validation process of entry pattern of the strategy.
Public methodOnValidateExitPatternFilter
Override to implement filter before validation process of exit pattern of the strategy.
Public methodPriceToTicks
Converts price to ticks depending on tick size.
Public methodReset
Public methodTicksToPrice
Converts ticks to price depending on tick size.
Protected methodTradingTimeFilter
Top
Fields
See Also