Widget specifically designed for scalping. Many settings to fit the instrument and view preferences to make it fit into your chart window how you like, even on mobile.
** I have 5 other features to add into this in the very near future, as I use this as my primary tool for Risk reward. This script will be updated in the near future as more features are coded into it. See bottom for notes on plans
Features:
Displays a quick view of the ATR value on the chart, in decimal PIPs or directly in Points - a key value for scalping using the DOM for point value settings and one click trading on fast time frames.
Automatic calculation of stop and target distance for a predetermined Risk Reward Ratio (Set with the settings panel), and then also displayed in PIPs or Points for easy use in quick trading.
Works on most all instruments/pairs/cryptos with multiple precision levels for correct values to be shown in the widget.
Fully customizable -
ATR period Base setting, just like a normal ATR indicator
Display in : PIPs or Points
ATR based stop distance, using a multiplier. 2 is the most common multiplier used, and the default setting.
Risk Reward Calculation using the Stop Loss value.
-Quickly helps with proper target and stop sizing for the volatility in the price on the current trade entry point.
-Set to any ratio you wish, from 1:0.1 all the way to 1:100 or more, unlimited R ratio settings to fit your strategy and risk tolerances.
Position anywhere on the chart window with 9 preset locations available (Pine script limitation)
Show as a column layout or a row layout
Customize the Size, with 5 preset widget sizes, from tiny to huge (Pine script limitation)
-Mobile Friendly - Tiny or Small may be too small on PC, but can be used for Mobile so the widget does not become too large over the chart.
Custom text, background, and boarder colors
Custom Boarder Size - 0 size is no boarder
Set up:
-Open the settings panel.
First section is the basic settings for the ATR - the length (Default is 14) and to use a PIP value display, or Point value display.
Here you also see a "Precision" Setting. **Because each instrument returns different precision ATR values, it is difficult to determine with code what those values will be ahead of time to do the math in the background. Even some 2 decimal instruments return 5 decimal ATR values, so this setting filters that** Just use the dropdown and choose how many decimal places the instrument has from 2 - 5 decimals
The second section is for risk and reward calculations, and can be disabled if you do not want to see these values.
The first value is the "ATR Multiplier" Typically, a 2x multiplier is used on the ATR to determine how far away to place your stop loss from the entry, placing it out of harm's way from normal market activity.
The second value is the Reward target distance, based from the stop loss size. This quickly calculates your target to match your intended reward ratio, saving some manual work to calculate this by hand every trade.
** Note: because of the math used in the code, you may see odd values on some instruments, like indexes. If you have the precision correct, try changing the "Show in Pips" to "Show in Points", as this may solve the issue.
The last two sections are purely for how the widget looks and how/where it shows on the screen. These can be set however you like. To have no boarder, just set the "Frame size" value to 0.
Additional Updates planned:
Pip value calculation (2 feature uses)
-This will serve 2 purposes. The widget will calculate the value of the trade based on the lot size. It will also have a risk limit, so if the ATR get's too high for the current risk settings, It will show red to warn you of a high risk situation before you trade.
Example, you have a set limit of 3 dollars per trade using .02 lot sizing. If the ATR get's too high, The Stop value will be more risk than you would like to use at that trade sizing. Reduce the trade size, or wait for ATR to come lower.
Purpose 2: lot size calculation, so if you wanted to maximize the use of risk available. If you wanted to risk 600 for example, it would use the ATR you have set for the risk, and determine the proper lot size for the amount of volatility in the market. This way, you Risk Exactly, or as close as possible to 600 for the the current trade conditions.
Extra use for this value: Show the Current trade amounts at risk and for gain in money values on the side of the pip/point value. Know what you're risking and also trading for in monetary value.
ATR candle Comparison- Early momentum Detection (2 feature uses)
Will show an additional section on the bottom of the widget to show how each candle compares to the one before, up to the last 5, and show if ATR went down, up, or stayed the same over the last 5 candles.
Show an additional symbol to indicate the current candle status in comparison to the close of the last candle. Real time of if the ATR is getting larger, smaller, or staying the same.