/*********************************************************************************************** Title: Multi-Timeframe Support/Resistance Indicator for eSignal By: Divergence Software, Inc. Web: http://www.sr-analyst.com ================================================================================================ Project Description: This script will draw up to 10 support/resistance lines based on upper and lower pivot points found in the price data. These pivot points are important because they represent levels where price action reversed direction in the past. This script will allow you to use bar intervals other than the interval you are charting to calculate these support/resistance lines. So, for example, you can load a 5-min chart of a security and then plot support/resistance lines based on that security's 60-min bar interval or even that security's Daily or Weekly bar interval. To take it a step further, you can load multiple copies into the same chart and view support/resistance lines drawn based on multiple bar intervals (e.g., load three copies of the script into the same 5-min chart. Set the first script to plot using 15-min data, set the second to plot using 30-min data and set the third to plot using 60-min data and you will see the current valid support/resistance lines from those 3 intervals.) The actual price pivots that the support/resistance lines are based on are identified with a user-defined Pivot Strength setting. The default value is 1, which means that a high pivot is any high that has a lower-high on either side. A low pivot would be any low that has a higher-low on either side. If the Pivot Strength setting were set to 2, then a high pivot would be any high that has 2 lower highs on either side, etc. You can adjust this Pivot Strength setting to suit your needs. Script Parameters: Interval: The bar interval to use for the support/resistance analysis. If you leave this field blank, the script will use the bar interval of the current chart. Note that the interval specified in this field should always be larger than the interval in your chart (e.g., if you are viewing a 1-min chart, you may want to load several copies of this script... one using a 5-min interval, a second using a 15-min interval, a third using a 60-min interval, etc.) Typically it would not make sense to use a lower interval in the script. PivotStrength: The number of bars on either side of a potential swing pivot high/low that must be either higher (for a swing low pivot) or lower (for a swing high pivot) to qualify as a true swing pivot. The default value is 1. Max Lookback: The maximum number of pivots to maintain in memory. The default value is 125 and the valid range is from 1 to 1500. A smaller number in this field (e.g., 50 or less) will result in faster script operation but may result in certain older support/resistance levels not being identified. Conversely, a larger number will result in slightly slower script execution time but the script will be able to correctly identify much older support/resistance levels. The default value of 125 should be acceptable for most situations. S/R Line Color: The color to use for drawing the support/resistance lines. S/R Line Thickness: The line thickness to use when drawing the support/resistance lines. S/R Line Type: Line type to use when drawing the support/resistance lines. Select from Solid, Dot, Dash, DashDot and DashDotDot. Line Start Offset: The bar offset from which to start drawing the support/resistance lines. Default is -20 which means the lines will be drawn starting from 20 bars back from the current bar position. Line End Offset: The bar offset at which to stop drawing the support/resistance lines. Default is 10 which means the lines will drawn 10 bars into the future. Draw: Select from "Interval & Price", "Interval Only", "Price Only" or "Nothing". Depending upon which one you select, the information will be printed to the right of the support/resistance line. Font Size: The size of the font to use when printing the information discussed in "Draw" above. Alert - Close Only: "T" (True) or "F" (False). Set this option to "T" (True) to check for alerts only on bar close (e.g., close price must exceed the support/resistance line). Set to "F" (False) to check for alerts on each new tick. Alert Use Sound?: "T" (True) or "F" (False). Set this option to "T" (True) to generate a sound alert when price breaks up through a support/resistance line or when price breaks down through a support/resistance line. Alert Use Popup?: "T" (True) or "F" (False). Set this option to "T" (True) to generate a popup alert when price breaks up through a support/resistance line or when price breaks down through a support/resistance line. Alert Use Email?: "T" (True) or "F" (False). Set this option to "T" (True) to generate an email alert when price breaks up through a support/resistance line or when price breaks down through a support/resistance line. Alert WAV File: Use this option to set the WAV file that will play when a Sound Alert is triggered. Default WAV file is DING.WAV. Disclaimer: For educational purposes only! Obviously, no guarantees whatsoever and use at your own risk. *******************************************************************************************************/