Please note, SharkIndicators does not provide any NinjaScript, programming, or coding support.
This information is provided as-is and for knowledgeable programmers.
Note:You must have ‘Developer Extensions’ checked when you ran the SharkIndicators Installer. That will also install the example code file.
This example file is included in the 'Developer Extensions' and can be found in the 'MyDocuments\NinjaTrader 8\bin\Custom\Strategies' folder as 'SiBloodHoundStrategExample.cs'. For NT 7, see the Downloads section below. You can safely delete this file when you are done with it.
This example illustrates the bare minimum BloodHound strategy implementation. It mimics the functionality already accomplished by the base class SiBloodHoundStrategy but overrides the OnBarUpdate method which can be extended with your code.
Entry signals are taken when BloodHound has a signal in that direction. This is governed by the active logic template.
To begin with a BloodHound strategy, derive your Strategy class with SiBloodHoundStrategy instead of the usual Strategy class as illustrated in line 8 above.
Also note that if you override the OnStateChange() method, you must call thebase.OnStateChange(); method as shown on line 45.
Finally you can see that the entry code uses the BloodHound indicator on line 80 and 90. BloodHound is an accessible property from the SiBloodHoundStrategy class, and LongSignals and ShortSignals are Series<bool> representing signals computed from BloodHound.
The SharkIndicaotor's Installer will install this file to the ...\NinjaTrader 8\bin\Custom\Strategies\ folder when the Developer Extensions are selected.
The last version to support Developer Extension is Ver 1.233.6603. It may be downloaded from the Changelog page. If you have a newer version installed, it must be uninstalled first and then restart the computer.
Download the import file below and import it into NinjaTrader 7 from the Control Center. Select the File menu » Utilities » Import NinjaScript.
Download import file for NT 7 (.zip)