/*********************************************************************************************** Title: Multi-Timeframe Trend Grid Indicator for eSignal By: Divergence Software, Inc. Web: http://www.sr-analyst.com ================================================================================================ Project Description: The MTF-TrendGrid indicator allows you to monitor the current trend in up to 5 different intervals. The default intervals are Weekly, Daily, 60-min, 15-min and 5-min but you can change these intervals to suit your needs. The determination of trend direction is based on the x-bar slope of a filter that you select. By adjusting the Filter Type and the Filter Length you can customize the trend direction calculation process to fit your style of trading (i.e., one trader may prefer to use the slope of a 20-period sma as a determinant of the current trend direction while another trader may prefer to use a 40-bar linear regression.) The available filters are: Simple Moving Average Exponential Moving Average Weighted Moving Average Jurik JMA (you must already be a licensed Jurik Tools user to use this option) Linear Regression The trend information is displayed in the form of a grid that you can position on your chart by adjusting the horizontal and vertical pixel coordinates in the indicator menu. For each interval being monitored, the grid displays the trend slope measured as the percent change (of the selected filter) from the current bar back to the lookback bar (default lookback is 1 bar) as well as the number of bars that the current trend has been in effect. The grid is also color-coded with user-defined colors for up-trend and down-trend. All of the trend calculations are updated in realtime. Note: Two versions of the indicator have been provided: MTF-TrendGrid and MTF-TrendGrid-IndicatorPane. Both versions perform the same function and the only difference between them is that the IndicatorPane version displays the grid in a separate indicator pane (as opposed to displaying the grid in the price pane). Use the version that best suits your needs. Usage: Pull up your eSignal Advanced Chart and load the MTF-TrendGrid indicator into your chart. It may take a few seconds for the indicator to fully load because it needs to request and retrieve bar data for each of the 5 bar intervals that are selected in the MTF-TrendGrid menu. Once loaded, you will see the grid display on your chart. Use the Alignment, Vert Offset, and Horz Offset indicator menu options to adjust the position of the grid display on your chart and use the Text Font Size option to adjust the size. Note: If, after the indicator completes the data loading process, you do NOT see the grid display on your chart, it may be because it is being drawn outside of the borders of your chart. Go into the indicator menu and set the Horz Offset option to a smaller value and the grid should appear. Script Parameters: Symbol: Use this menu option to set an alternate symbol for the MTF-TrendGrid indicator to use. Typically you would leave this field blank (the default value) so that the MTF-TrendGrid indicator would use the symbol that you are currently charting. If you want to chart one particular symbol but view trend information for a different symbol then enter that symbol in this field. Filter Length: This is the input length (i.e., period) that will be used for the filter that you select. The default value is 20. The valid range is 1 to 9999. Filter Type: This is the filter that will be used to measure the trend direction. You can select from sma (simple moving average), ema (expoential moving average), wma (weighted moving average), jma (Jurik moving average), and linReg (linear regression). Note that the jma option (i.e., Jurik moving average) will only work if you are currently subscribed to the Jurik tools. The default value is sma. Filter Bars: This is the number of bars over which the trend slope will be measured. The default value is 1. The valid range is 1 to 9999. Trend Up Color: This is the color that will be used in the grid display to signify an up trend. The default color is light-green. Trend Dn Color: This is the color that will be used in the grid display to signify a down trend. The default color is red. Title Color: This is the color that will be used in the title row of the grid display. The default color is light purple. Text Color: This is the color that will be used to draw the text in the grid display. The default color is black. Text Font Size: This is the font size that will be used to draw the text in the grid display. The default value is 12 and the valid range is from 8 to 55. Note that the actual grid will expand/shrink based upon the font size selected. Interval #1: This is the first interval that will be monitored. The default value is "W" for Weekly. You can enter any valid eSignal bar interval in this field. Enter "0" (i.e., zero) in this field if you wish to disable this particular interval. Interval #2: This is the second interval that will be monitored. The default value is "D" for Daily. You can enter any valid eSignal bar interval in this field. Enter "0" (i.e., zero) in this field if you wish to disable this particular interval. Interval #3: This is the third interval that will be monitored. The default value is "60" for 60-min bars. You can enter any valid eSignal bar interval in this field. Enter "0" (i.e., zero) in this field if you wish to disable this particular interval. Interval #4: This is the fourth interval that will be monitored. The default value is "15" for 15-min bars. You can enter any valid eSignal bar interval in this field. Enter "0" (i.e., zero) in this field if you wish to disable this particular interval. Interval #5: This is the fifth interval that will be monitored. The default value is "5" for 5-min bars. You can enter any valid eSignal bar interval in this field. Enter "0" (i.e., zero) in this field if you wish to disable this particular interval. Alignment: Use this menu option to select the grid alignment. You can select from "Bot of Chart" or "Top of Chart". If you select "Bot of Chart", the vertical offset will be based on the bottom of the chart. If you select "Top of Chart" the vertical offset will be based on the top of the chart. The default value is "Top of Chart". Vert Offset (Pixels): Use this option to set the vertical offset of the grid in pixels. The vertical offset will be measured against either the top of the chart or the bottom of the chart (see Alignment above). The default value is 10 (pixels). Horz Offset (Pixels): Use this option to set the horizontal offset of the grid in pixels. The default value is 700 (pixels). Disclaimer: For educational purposes only! Obviously, no guarantees whatsoever and use at your own risk. *******************************************************************************************************/