Created
July 10, 2012 16:54
-
-
Save DexterHaslem/3084661 to your computer and use it in GitHub Desktop.
runtime indicator
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
protected override void OnBarUpdate() | |
{ | |
string indicator = "EMA"; | |
Type indicatorType = Type.GetType("NinjaTrader.Indicator." + indicator); | |
IndicatorBase indicatorBase = (IndicatorBase) Activator.CreateInstance(indicatorType); | |
Print(indicatorBase.GetHashCode() + ":" + indicatorBase.GetType().FullName); | |
indicatorBase.BarsRequired = BarsRequired; | |
indicatorBase.CalculateOnBarClose = CalculateOnBarClose; | |
indicatorBase.ForceMaximumBarsLookBack256 = ForceMaximumBarsLookBack256; | |
indicatorBase.MaximumBarsLookBack = MaximumBarsLookBack; | |
indicatorBase.Input = Input; | |
indicatorBase.SetUp(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment