The PriceActionSwing indicator for NinjaTrader 7.0 calculates swings in different ways and visualize them. It shows swing information like the swing length, duration, volume,... It contains a lot of features. It is also useable on the Market Analyzer.
The package contains 3 indicators: PriceActionSwing
- standard swing indicator with visualization and swing information PriceActionSwingPro
- Draw automatically Fibonacci extensions and retracements
- Calculate a swing statistic
- Calculate and visualize ABC patterns
- Risk management (automatically for ABC patterns)
- Calculate and visualize divergence based on an indicator
- GomCD (uncomment the "region GomCD" parts in the source code) PriceActionSwingOscillator
- swing trend visualization
- developing swing volume (repainting)
Useful to see/trade price action with HH, HL in uptrends and LL, LH in downtrends and patterns like double top/bottom, triangle,…
Version 17 - June 5 2014
- Changed the code structure for simpler access from strategies and other indicators If you use PriceActionSwing within other files, make sure you have a backup from the old version
- Added swing tick and swing percentage calculation
- Added swing calculation based on close values
- Added seperate swing price output
- Added developing GomCD output since the last swing
- Improved risk management items
- Added risk management tab
- Added different alerts
Version 18 - June 15 2014
- Fixed minimum swing size to < 1 for percentage settings
Starting from version 17 NinjaTrader 6.5 will not longer be supported. Starting from version 19 NinjaTrader 7.0 will not longer be supported get NT8 version here
COMPATIBILITY:
NinjaTrader 6.5: NO
NinjaTrader 7.0: YES
NinjaTrader 8.0: NO, see NT8 version here
May 17th, 2013
Size: 148.37 KB
Downloaded: 5310 times
1384
devdas
Exported using NT Version 7.0.1000.11
Indicator will only run on NT 7.0.1000.4 or later.
The VisualSMA is a MTF (multi-timeframe) version of the Simple Moving Average. It will plot on any chart and allows to calculate the moving average
- from minute bars
- from second bars
- from tick bars
- from range bars
- from volume bars
For example you can display an hourly SMA on a 235 tick chart, or display a 11-period SMA calculated from a 500 tick chart on a 7 range chart.
The indicator has three modes to display the moving average:
StrategicMode: The first bar series collects the values from the secondary series without any lag on historical data, but a 1-tick lag on real-time data. This mode does not repaint, but shows the values originally recovered from the secondary bar series. On the chart the indicator in Strategy Mode is plotted yellow.
FirstTickMode: To avoid the lag for similar bars with identical time stamps, the indicator repaints the indicator value for the prior bar, after the first tick of the current bar has been registered. The one-tick repainting reduces the lag. On the chart the FirstTick Mode is shown in red.
Visual Mode: To make it easier to use the indicator visually, the indicator interpolates the distance between two consecutive bars of the secondary bar series. The interpolation algorithm works in real-time and simulates the CalculateOnBarClose = false mode for the indicator relative to the secondary bar series. It repaints the current leg of the indicator back to the prior bar of the secondary series. The interpolation adapts itself to equidistant or non-equidistant charts. The Visual Mode is shown in aqua.
This indicator comes as a protected assembly, so you cannot directly access the code.
Update August 30, 2011: 1-Tick Repainting for VisualMode and FirstTickMode was only enabled for fixed period bars. It is now also available for other bar types.
Update September 6, 2011: Bug fixed. VisualMode interpolation could be a few ticks off on real-time data.
Update November 9, 2011: Indicator entirely recoded, robustness and speed improved, lag reduced.
Update November 23, 2011: Indicator was lagging with CalculateOnBarClose = true setting. Lag is eliminated.
Update January 5, 2012: Option added to select color according to the slope of the VisualSMA. Paintbars added as a trendfilter.
Update August 15, 2012: Code updated to allow for displacement of indicator.
Update September 29, 2012: Renko option removed. Indicator could not always be called from a strategy, bug removed.
Please remove prior versions of the indicator, before installing the new release:
(1) Remove old assembly via File -> Utilities -> Remove NinjaScript Assembly.
(2) Shut down NinjaTrader and restart it.
(3) Install new file via File -> Utilities -> Import NinjaScript.
Decycler indicators Exported with NinjaTrader 7.0.1000.30
Note: The download on this entry and the one on the SimpleDecycler entry are the same and contain both indicators.
Revised 11/1/15
Revisions:
1 Ability to change plot colors and line widths.
2. Remove all code related to the signals produced for Bloodhound.
Another indicator which contains Bloodhound signals will be posted on the Bloodhound thread here.
3. Add basic signal codes to replace the Bloodhound codes.
4. Correct minor problem in code in formula calculation
5. Change the percent parameter to accept the more standard notation xx.y (%).
>>>End Revisions 11/1/15<<<
The two indicators provided, the Decycler Oscillator and the Simple Decycler, are based on the writing of John F. Ehlers published in the September 20015 issue of Stocks & Commodities magazine. The implementation used as the basis for this version was provided by NinjaTrader(NT). Although both indicators are contained in the download they are described separately. This entry describes the DecyclerOscillator.
The screenshot shows the DecyclerOscillator with modified version of the SimpleDecycler set to appear like the NT provided version (which can be downloaded here). Installing the NT version will not disturb the indicators provided as they are prefixed with “fpg”.
In the article Mr. Ehlers describes a class of filters known as high-pass filters which “allow the high-frequency components in the data to pass through to the filter output, and reject the low-frequency components”. He goes on further stating, “Since high-pass filters have very little lag, here is the trick to computing a decycler: Subtract the high-pass filter output from the data input.” This is performed in the partner indicator, the SimpleDecycler. He also states that, “You can virtually eliminate lag by getting rid of those low-frequency components.”. Both indicators contain the same algorithm (which is left to the interested math and EE gurus to figure out what he is doing) for identifying the high-pass frequencies.
The article states that the oscillator is useful when two instances , with different parameters, are placed in the same sub-graph. The NT implementation requires this to be done manually which, among other things this modification can do optionally. There are 2 controlling parameters, the HPPeriod (default 125) and the K value (default 1). According to the article, “The second instance is plotted at 80% of the HPPeriod with an input K value of 1.2. The basic idea is to compensate for a 20% reduction in cycle period with a 20% increase in the amplitude swing (the K value) of the indicator.”.
Ehlers notes that “there will always be some whipsaw conditions, but these are relatively easy to remove with other conditional statements in the code.”. Unfortunately he does not offer any suggestions here. Another important item to note, the default HPPeriod is set to the value of a half year on a day chart, likely being used for detecting cycle reversals on stocks. However as further stated in the article, “Decyclers and decycler oscillators can be used over a very wide range of input filter parameters”, but here too he offers no suggestions. This will be an experiment to be conducted by the user. However, setting it too low does introduce choppiness.
Enhancements:
1. The ability to request either the Slow, Fast, or Both plots (the “Plots Type” option).
2. Automatically adjust the fast indicator parameters by the specified percent (the “Percent” option) or to use the parameters specified by the user (the “ AsSpecified” option).
3. Three signaling options are provided: Off, Basic, and Extended (experimental for Bloodhound users). The Basic option provides the standard IntSeries values for the crossing (1, 0, -1). Extended signaling is described in the BloodHound thread here.
4. Optional smoothing for both the Fast and Slow Plots
Caution:
If the Extended signaling option is selected additional but non-conflicting signals are sent to the same IntSeries used by the Basic signaling option.
Credits with my thanks to:
1. @Zondor and @Aligator for a formula used in the Extended signaling
2. @Jack22 for the formula and supporting code.
Change Log
9/29/2015 :- Initial release
10/1/2015 :- Correct error in algorithm code for calculating Fast plot in DecyclerOscillator
11/1/2015 :- Revisions are described at the top of this page
February 26th, 2017 11:05 AM petrukwannabe thank you
February 3rd, 2016 10:11 PM angela d I'm unable to compile this cs in the indicator editor.
June 13th, 2015 02:46 PM mrvtibbs Converted .CS file to zip file and got error message that likely file is corrupt and cant be imported...and cannot find
central directory..any suggestions on how to proceed from here?
Thanks
VSand
August 30th, 2014 10:28 PM landau Nice work. But I don't understand how to import this into Ninja Script since it is not a zip file.
Carl
June 30th, 2014 10:17 PM zohar Best indicator. Indicator has continued this version but this indicator to me most comfortable. What's great about where
that rectangle around which are traded on the bid or ask. It is much more comfortable the second version where there ar
e only traded on the line. It is good when trading fast and want to see side traded my hands.
September 6th, 2015 05:10 AM Sezor Thz - haven't tried it yet
August 30th, 2013 03:57 PM sdp0024 I'm new to this forum and wanted to confirm that these are dropped in the same folders as they are in the download folde
r. And yes, inputs would be very helpful.
April 29th, 2013 08:54 PM SarahKrantz Would be really helpful if you showed the inputs that generated that Performance Report.
April 28th, 2013 09:50 AM Mumorex thank for sharing. Will play ;-)