I came across "McGinley Dynamic" in a thread on this forum. On further investigation I found two entirely different formulas referred to by that name. This indicator implements a variation based on the following formula:
v[0] = v[1] + (Close[0] - v[1]) / (.618 * n * (Close[0] / v[1]) ^ 4)
Now that I can see the result, it doesn't appear to me to be any more useful as an average than an EMA of the same period. However I think it may make a good trigger line vs an EMA of the same period.
September 7th, 2010
Size: 2.12 KB
Downloaded: 287 times
634
fluxsmith
A simple indicator to show the first two sub-sessions highs and lows, as defined by user inputs for:
sub-session 1: from start of session until end of sub-session 1
sub-session 2: from end of sub-session 1 to end of sub-session 2
So there are two input parameters for setting the time when the first sub-session should end and when the 2nd sub-session should end.
24 hour clock values only and I still have to code a time-zone parameter to take care of special situations like the daylight saving time shift difference between London and New York - America changes over 2 weeks prior to the EU in spring, so at the moment if that affects you, you would have to adjust the parameters temporarily - i.e. it's necessary to adjust these input parameter values in March and in October when there is a period after the USA clocks change and before the European clocks change, if you're based in the EU and your sub-sessions define non-EU time-zones.
Basically if you are using the US East Coast time zone, you won't need to worry about that.
Change Log
Changed name to PermaCodeSubSessions
fixed bug where data gaps would snarl up session start times
February 5th, 2013
Size: 2.20 KB
Downloaded: 285 times
1360
Adamus
Maximum value seen in period. Should return the same values as the standard MAX, which as of b18 has been fixed to reduce iteration. With that fixed the only advantage this has over the standard is memory reduction when used as a component and not displayed. (Both versions are now efficient with CalculateOnBarClose == false.)
Version 2 - Corrected calculation errors when COBC == false && Input != High
July 4th, 2010
Size: 2.31 KB
Downloaded: 278 times
527
fluxsmith
Symbol Range, Version 1 -
This indicator allows a pretty quickly analysis of any chart data to determine the $Dollar and Tick range each day during any intraday time period for whatever symbol you have charted.
It prints data to the Output Window in Ninja so be sure you have that open. You can save that data as a .csv file and then open in Excel if you want to analyze further. I purposely put commas between the labels and the data just so I could import to Excel. If you use a super fast chart (like a 1-tick) it will make your CPU crawl so be careful not to have too many days of data on your chart. For a 1-tick chart, less than 15 days isn't bad. For minute data, years is very quick.
"TickRangeEachBarSummed" for a 1-tick chart represents the total "travel" of every wiggle in price. This is of course dependent on your data provider and may vary depending on if they filter the data you are charting. "TickRangeEachBarSummed" for any other chart type is the addition of every bar's High minus its Low.
November 22nd, 2013
Size: 2.39 KB
Downloaded: 278 times
1459
MBAGearhead
William Blau's True Strength Index
By request I'm reposting jhlTSI with support for additional averaging methods for the signal line. I'm posting it as a new version instead of updating the original post, as more methods mean many more dependencies. If you're not interested in the additional averages you should download the earlier jhlTSI.
Minimum value seen in period. Should return the same values as the standard MIN, which as of b18 has been fixed to reduce iteration. With that fixed the only advantage this has over the standard is memory reduction when used as a component and not displayed. (Both versions are now efficient with CalculateOnBarClose == false.)
Version 2 - Corrected calculation errors when COBC == false && Input != Low
Explanation on how to set this indicator up, and copy values into excel are here:
The specs for the indicator are as follows:
Quoting
1) Excel sheet : Columns
Date , Volume , High , Low and Closing Prices
2) Day types : Buying Day (1) , Selling Day (2), Sell Short Day (3)
3) Collect the data as stated in step 1) for the past 10 days . Lowest price of the 10 day's Low column can be named Buy Day (1)....from there naming is automatic .. Next day (2) is Sell day and following day (3) is sell short day
4) Ideally on Buy Day (1) , low needs to be made first . (Buy day column cell can turn green if this condition is true) . For other 2 days high needs to be made first (Buy day column cell can turn red if this condition is true)
5) Once Sequence is identified, it should continued for every day market Opens, even for few hours . Holidays should not be counted.
6) The (D) Decline Column : The difference between previous day high and today's low
7) The (R) Rally Column : The difference between previous day low and today's high
8) The (BH) buying High Column : The difference between today's high and previous day high
9) The (BU) buying Under Column : The difference between today's low and previous day low
Toggles session break lines on and off for a cleaner chart when doing your analysis / trading.
Thanks to others who had coded the toggle buttons for other indys. Uses unsupported code for NT. Nothing sinister just ChartControl stuff and PlotSessionBreaks.
Puts a dot on top of volume bar when your desired "High" volume criterion is met.
In past I had a horizontal line at my desired volume, but could not tell for sure until I checked the bar.
This way NT7 does the checking for you.
Hope this one is not considered to simple.
I am fairly new to programming and this indicator plots a Dot at the top of the volume bar or where the volume bar would be when the last bar exceeds a user selected volume in your indicator panel (default is 30,000). It can be used with or without VOL. (Best to load both in the same panel)
Also the Blue dot works best at size three, but that too is selectable (You don't even need to use the dot and select another plot style.)
Fairly simple code and easily changed. Works with any time frame that VOL works with; however VOL indicator is not totally necessary, but helps for visual display.
Also if you want to just unzip this indicator before importing it to NT7: DotForVol.zip contains three files: DotForVol.cs This is a text file containing my code. If you rename it to DotForVol.txt you can use any editor to view the code. DotForVol.dll Compiled code for NT7 Info Not sure how this file works, but sure there is a reason for it, as NT7 exporter put it in there.
This is my first version 1.0.0.1 5/28.2014
Second version 1.0.0.2 6/2/2014 (Added an offset to plot above volume bar and a default of 3 for dot size. All of which can be changed without recoding the indicator the offset default is 10,000 and shows in MISC and can also be changed.)
20 OCT 2014 Added sound option for indicator. Couldn't figure out quickly how to include while zipping with NT7 and will include .WAV file separately. Just copy the .wav file into your /sounds/ folder and it should work. Note: this is a work in progress for me. I have borrowed code from MACD Color, and will be working in the future to clean up my code. Also this time I zipped without creating the .dll files. I learned that doing it that way makes it so you can see my code. Before I thought I had done this... Who knew there were different .cs files with same name when you make an indicator depending on how it is compiled. Man I have a lot to learn. Well Uploading now as I have taken a short break today to finish this. Okay... Well didn't have time today to make this perfect Here is link to update in my journal where I uploaded the files indicator and wav file. I'll do my best to fix things up and get back to this later. Just don't have the time for perfection right now.... https://nexusfi.com/trading-journals/27901-my-yellow-brick-road-bd92154-30.html
February 9th, 2011
Size: 4.61 KB
Downloaded: 242 times
821
fluxsmith
Returns the same values as the NT supplied ADX, but has at least a 12K memory advantage. Both do not iterate, so are reasonable to use with CalculateOnBarClose == false, although they are somewhat computationally intense. Version 1.0.
Standard EMA re-programmed to display fractional pricing to match Interest Rate Futures pricing.
[Will also properly display decimal pricing on contracts other than Interest Rates]
This version corrects a bug in the elapsed time calculation when a session break occurs. This may or may not be noticeable when a session break occurs during a weekday but is most definitely noticeable over a weekend session break.
Exported with NinjaTrader: 7.0.1000.34 Release Date: 11/17/2017
Indicator Name: fpgExportCsvData
Updated 12/6/2017
Fixes and Enhancements are as follows:
Fixes:
Correct error writing to Closed file on termination
Cleaned up Error messages, Initialization, and Statistical messages
Eliminate extra .csv header on appended file
Eliminate the Print Error option, always print the errors to the Output Window
Other minor fixes
Enhancements:
Remove requirement for the slash before file name
Further qualify the file name by adding "_Detail" to the end
Supports all bar types. Removed the bar type restriction and unneeded override facility
Implemented a directory service to track the created export files.
Shorten the .csv headers to save column space in the excel file.
Added in an ATR, EMA, and SMA with adjustable periods
Implemented the option to include up to 5 other MAs from a list of about 30.
Notes:
The Directory file is in the same folder as the data files
The .csv headers are different in that they are shorter and not very readable. A spreadsheet had been provided for
both the Detail and Directory files and can be found here.
Even though the headers are different with the exception of the additional columns the order is the same therefore
any Excel sheets you may have designed can still be used.
The provided and optional moving averages do not plot
Warning:
Installing this version will replace the existing one. Copy the original to a different folder if you need/want to
revert to the previous version.
Original Post Starts here
This indicator collects various chart data and exports the data to a .csv file which can be directly imported into Excel for further analysis. Both the path and filename must be specified by the user. The indicator was designed for traders that may not have Excel on their trading platform or have no need to do any real time analysis.
There are four ways that the data can be filtered as shown below. Data that is filtered by a higher level is passed to the next lower level.
Historical Only, RealTime Only, or Both
All dates (as controlled by the Days to load in the Data Series) or by selected date ranges. Up to 3 non-contiguous ranges date ranges can be specified (but must be in oldest to newest order).
All days of the week or by selected days of the week.
All 24 hours or by selected time ranges. Up to 3 non-contiguous time ranges that can be specified (again in order). The time ranges are specified in 24 hour format.
The input format of the date and time parameters are described in the indicator parameters and must be exactly as shown. However, there is a special use of zeroes and a minus one as follows:
A zero in the “Start” field for either the date or time section means to start collecting from the first bar according to what was specified for number 1 above. The zero is only valid for the first entry (pair 1) of both date and time.
A zero in the “End” field of either the date or time section means to continue collecting data unless otherwise controlled by a higher level parameter. If Used, a zero in the End field can only be in the last used pair.
Although zeroes can be specified in both the Start and End parameters (only in pair 1) of either the date or time section doing so is the same as the “All” option and is internally changed to an All setting.
A minus one is used only as a place holder and is not valid in an enabled pair
Notes:
If using either non-contiguous dates or times be careful when doing Excel computations between them. An easy way to check for this condition is to check for a break in the sequence of the bar numbers.
By default the indicator checks for Renko and Range bars and has been tested with them. However, this check can be turned off so that other bars types can be used, but only limited testing has been performed. If you have a problem with other bar types PM me with the details.
The complete path name must be used in the format Drv:\RootFolder\OneOrMoreSubfolders\Filename. If drive is not specified it defaults to the C: drive.
The path and filename are separate entries and must be entered as documented in the parameter description. The .csv file extension is automatically added and must not be specified. If the file does not exist it is created. If the file does exist the newly collected data is appended to any data that was previously collected. If for some reason the file cannot be opened an error message is displayed on the chart and a message is written to the NT log that contains additional information. The most likely causes are either the path or path permissions are set incorrectly.
WARNINGS:
if the file already exists the data is appended to the file therefore the data can be duplicated depending on the parameters used. This can easily happen if a refresh has occurred without an intervening file name or collection parameter change.
In most situations the last data buffer is not flushed out until the indicator is removed, or the chart or workspace has been closed, except as noted below.
Exceptions:
If Historical Only data is being collected the first RealTime record stops the recording and the file is closed, and,
When the last date range has been collected the recording stops and the file is closed.
In all other situations the indicator, chart, or workspace must be closed to flush the last buffer.
The easiest way to use this indicator is to create a new chart with the desired bar type and Data Series declarations, preferably in its own workspace, and add only this indicator setting the desired parameters. The workspace can be run in the background if RealTime Only or Both are being collected. For Historical Only, set up the data collection in the same way but depending on the amount of historical data being collected it may not necessary to run it in the background as it is relatively fast.
Some programs (Notepad++, …) will allow access to the file even without it being closed. Moving or deleting will require that the file be in a closed state.
Parameter checking is performed and if there are errors a warning message is displayed in the lower right section of the price panel. Also, detailed error messages can be displayed to the Output window if the appropriate parameter is set to true. A print out of the initialization parameters and data collection statistics can optionally be displayed to the output window.
The screen shot shows a partial file that was imported into Excel with the data fields names at the top.
Change Log Date............Description
12/11/2017......Fixes elapse time calculation over session break
12/6/2017........Fixes and Enhancement described above
11/17/2017......Initial release
April 18th, 2017
Size: 5.84 KB
Downloaded: 216 times
1851
jta3
Returns the Pearson product-moment correlation coefficient of the input series. This requires iteration, so should probably be used with CalculateOnBarClose == true.
Version 2 - Solves a /0 error, returns 0 if price is unchanged for all of the bars in the calculation.
A signal to noise ratio. Returns the total delta for the period divided by the sum of each individual period's delta. Does not iterate, so can reasonably be used with CalculateOnBarClose == false. Might be known by other names, documented as 'Efficiency' in 'Smarter Trading' by Perry J. Kaufman. Version 1.0.
This is the initial release of a NinjaTrader CORREL factor function. This function is similar to Excel's CORREL function but it allows you to find the correlation factor between two indicators as a function of time over a defined period.
February 26th, 2014
Size: 4.18 KB
Downloaded: 206 times
1526
NJAMC
Linear Regression Slope. Should return the same values as the standard LinRegSlope. However, the standard version iterates on every update, making it especially inefficient for intrabar (tick) data. This version does not iterate on intrabar updates. Version 1.0.
Here is a method to invert charts of VIX, ZN, ZF, ZB if you prefer looking at the mirror image rather the default chart. Full credit to the folks over at Ninjatrader for posting this.
The indicator draws a mirror image of the default chart as a line chart, candlesticks are not supported. The dataseries you want to invert should be specified in the "Input Series" option of indicator. See link above for notes on the custom range.
October 9th, 2013
Size: 5.67 KB
Downloaded: 201 times
1446
bluecrow
Name: DrawCandleClose / DrawCandleCloseWhite / DrawCandleClose Black Version 1
Author: James R. Walker
These indicators were created to show the Closing price when the CandleStick Opening and Closing price were the same and a Transparent Body Outline color was specified, when the Background color was not White. Standard NT 7 CandleStick Closing price is drawn with the Outline color and is Transparent when that color is Transparent, if the Background color is not White.
These Indicators are obsolete.Instead use fix described below. Attached file is a dummy file to meet posting requirements. Please download the file to log your interest in this fix, but do not install downloaded file. Instead, apply the fix manually. Never blindly replace standard files because of the risk of back leveling.
Examples:
Top CandleStick: Chart Style = Candlestick with Black outline.
Middle CandleStick: Chart Style = CandleStick Transparent Outline After Fix
Bottom CandleStick on Black Background After Fix:
Chart Style = CandleStick, Candle Wick = White, Candle Outline = Transparent, Chart Property Background = Black and All markings that were Black = White.
NT7 Fix for Tracking ID # SFT-818 , Missing Doji when CandleStick Outline Transparent.
Description: Always draw the Doji Close line with the Wick Color instead of the Outline Color. This eliminates the inefficiency of having an Indicator check every CandleStick bar close for Open==Close and overwrite the already drawn Transparent Close line.
Applying this fix in no way changes the appearance of CandleSticks that have bodies. This can be verified with the examples provided.
NT7: Line 490 \Documents\NinjaTrader 7\bin\Custom\Type\@ChartStyles.cs
Replace:
graphics.DrawLine(Pen, x - barWidth / 2, close, x + barWidth / 2, close);
With:
graphics.DrawLine(Pen2, x - barWidth / 2, close, x + barWidth / 2, close);
I recommend the following to apply the fix. It may seem complicated but will save you time in the long run. Note that it is undocumented but NT Backup never includes files that begin with the character "@".
Attached file is a dummy to meet posting requirements.
1) Copy \Documents\NinjaTrader 7\bin\Custom\Type\@ChartStyles.cs
2) Paste the file and rename it @ChartStyles.cs Before SFT-818
3) Edit @ChartStyles.cs with with Notepad
4) Make change to line 490 with Notepad
5) Compile any NT file with NT Editor. New @ChartStyles.cs will be used in the compile.
6) From next start of NinjaTrader, CandleSticks will use Wick Color for Doji Close line.
7) Copy \Documents\NinjaTrader 7\bin\Custom\Type\@ChartStyles.cs
8) Paste the file and rename it @ChartStyles.cs After SFT-818Any NT updates will replace @ChartStyles.cs so you will have to make the changes again.
You can use Winmerge to compare updated @ChartStyles.cs and @ChartStyles.cs After SFT-818 and reapply fix to updated, after NT update.
Cleanup:
1) Delete Indicator DrawCandleClose.cs, DrawCandleCloseWhite.cs, and DrawCandleCloseBlackif, if they exist, from \Documents\NinjaTrader 7\bin\Custom\Indicator.
2) Start NT Editor > Compile any Indicator to remove deleted Indicators.
NT will automatically remove the Indicator from any chart that use it.
Test:
Create a CandleStick chart with Transparent outline. Verify that you see Doji.
April 22nd, 2015
Size: 3.82 KB
Downloaded: 198 times
1630
gregid
Chande Momentum Oscillator. This should return the same values as the standard supplied version; its advantage being ~4-6K less memory consumption. It does not iterate (neither does the supplied) so is reasonable to use with CalculateOnBarClose == false. Version 1.0.
February 15th, 2011
Size: 3.11 KB
Downloaded: 194 times
836
fluxsmith
Wikipedia calls this a 'Modified Moving Average'. Traders may know it as Welles Wilder's Moving Average, as it is the averaging method used in many of his indicators.
It's conceptually simpler than an EMA, the basic formula being:
average = (newValue + priorAverage * (n - 1)) / n
However, for any number of periods 'n', the outcome is identical to EMA(2 * n - 1). Since my basic indicators are all about efficient code reuse that is the implementation used here. Using the EMA formula is also slightly more CPU efficient than the formula above.
This indicator plots the up/down limit prices for grain futures, using the contract rules and the previous day's official close.
It works with CMEGroup/CBOT regular & mini-sized futures for Corn, Wheat, Rough Rice, Soybeans, Oats, Soybean Oil, & Soybean Meal
Grain price limits are set based on the previous day's official close. But for grains the previous day's official close is set by the Pit Committee, it cannot be calculated from intraday data. This indicator gets the official close using daily bars, which aren't plotted but are needed for the calculation.
This requires that your data provider use the official daily close for its daily bars. IQFeed and Kinetic do. Interactive Brokers does not (IB's daily bars will give the price of the last trade). If you want to use this indicator with IB or some other intraday data provider who doesn't provide the official daily close, you can first connect to Kinetic (free for daily data), then to IB.
Near the expiration of the contract, when the limits come off, nothing is plotted.
This indicator will require editing if CMEGroup changes the contract rules.
Exported using NinjaTrader Version 7.0.1000.7
12/5/2011: Fix to include Corn limit price rule change of 8/22/2011
October 29th, 2011
Size: 5.63 KB
Downloaded: 188 times
1033
kevind
NT7 Workspace Startup tool
I built this little tool to help reset my _WorkSpace.xml file.
Example of use:
Upon coding an indicator you forget to dispose of a resource so when pressing F5, NT7 crashes. The problem is NT7 will reload that last workspace....only to crash again....and again. You want to restart with another workspace loaded so you can fix the problem, right?
Well, the old and tedious way is to open your _WorkSpaces.xml file, search for Workspaces and delete the entries, replacing them with one/some default templates. After doing this a hundred times...I decided enough is enough
(I believe you can safe load NT7 to do a similar job, but I like the flexibility of choosing my own workspaces to load.)
When NT7 is closed just run the .exe file and drag and drop which workspaces you want to load up upon the next restart. Instructions are inside the zip file. Do not import into NinjaTrader!
If you wish to see inside the .exe file just use any decompiler like DotPeek.
April 18th, 2017
Size: 6.02 KB
Downloaded: 178 times
1849
jta3
I am in the process of running replay for 10 days to build data for the persistent indicators recorded by Gom & Zondor Recorders for the new front contract months.
Since I had errors it was necessary to remove previous files before starting
Ex: 6E 06-10.Binary.dat
Ex: 6E 06-10.Mili.dat (think this is the name)
Run a second chart for as long as you need - I do a week - with the following template for each instrument.
This template uses 2 recorders (Gom & Zondor) both recording Binary, milisecond could be used, for a total of up to 4 files of recorded for each instrument. I run one Instrument at a time: Takes less than 30 min.
But someone can play with this...
.
Do it once there and keep up with the data.
Other options are for: IRT, QCollector & QcollectorIQ.
July 3rd, 2010
Size: 6.55 KB
Downloaded: 174 times
521
fluxsmith
May 31st 2018 v1.0
This Indicator displays the time elapsed since last execution and was inspired by the work of Lucas (Rainbow from the the NT forum) and an open source indicator he offered which toggled trades.
I am self taught and although this indicator has shown to be reliable and stable, the bulk of his work is advanced and credit should go to him.
It's common for people to look at how large the upper or lower 'wicks' or 'shadows' are in comparison to the range of a bar. In writing strategies that do so, I got tired of re-re-coding calculations to look for especially large ones.
So, I created an indicator that shows the upper and lower wick size as a percentage of the bar's range. So, now, if I want to specify a wick that's greater than 50% of the bar's range, I can just look for instances where the indicator values are UpperWick > 50 or LowerWick < -50.
If you find looking for negative numbers cumbersome, edit the indicator and reverse the LowerWick calculations, from either (Low[0] - Open[0]) or (Low[0] - Close[0]) to (Open[0] - Low[0]) or (Close[0] - Low[0]), respectively. Then, all the histogram bars will point upwards and you can make your code always look for positive values.
I hope some of you find this indicator handy.
I neglected to account for instances where Range() is zero, so the original indicator sometimes stops working. This newer version corrects that problem.
August 13th, 2017 11:18 AM gringa Thank you! I just came across an online discussion about this indicator forTC2000, and am happy that it is available for
March 4th, 2017 01:10 AM HappyLife Thanks for the thought but a couple of things: code appears to be at line 489 (Notepad ++) and the compile fails in step
5. So can't say the work around provided here fixes the issue for NT7