Supertrend with TP by Furkan SancuSimple Supertrend strategy with Take Profit levels.
Note: Make sure TP amounts add up to 100.
Opens a position with Supertrends strategy then adds Take Profit points with certain amounts of current position.
Cari skrip untuk "tp"
Big Snapper Alerts R3.0 + Chaiking Volatility condition + TP RSI//@version=5
//
// Bannos
// #NotTradingAdvice #DYOR
// Disclaimer.
// I AM NOT A FINANCIAL ADVISOR.
// THESE IDEAS ARE NOT ADVICE AND ARE FOR EDUCATION PURPOSES ONLY.
// ALWAYS DO YOUR OWN RESEARCH
//
// Author: Adaptation from JustUncleL Big Snapper by Bannos
// Date: May-2022
// Version: R1.0
//Description of this addon - Script using several new conditions to give Long/short and SL levels which was not proposed in the Big Snapper strategy "Big Snapper Alerts R3.0"
//"
//This strategy is based on the use of the Big Snapper outputs from the JustUncleL script and the addition of several conditions to define filtered conditions selecting signal synchrones with a trend and a rise of the volatility.
//Also the strategy proposes to define proportional stop losses and dynamic Take profit using an RSI strategy.
// After delivering the temporary ong/short signal and ploting a green or purple signal, several conditions are defined to consider a Signal is Long or short.
//Let s take the long signal as example(this is the same process with the opposite values for a short).
//step 1 - Long Definition:
// Snapper long signal stored in the buffer variable Longbuffer to say that in a close future, we could have all conditions for a long
// Now we need some conditions to combine with it:
//the second one is to be over the Ma_medium(55)
//and because this is not selective enough, the third one is a Volatility indicator "Chaikin Volatility" indicator giving an indication about the volatility of the price compared to the 10 last values
// -> Using the volatility indicator gives the possibility to increase the potential rise if the volatility is higher compared to the last periods.
//With these 3 signals, we get a robust indication about a potential long signal which is then stored in the variable "Longe"
//Now we have a long signal and can give a long signal with its Stop Loss
// The Long Signal is automatically given as the 3 conditions above are satisfied.
// The Stop loss is a function of the last Candle sizes giving a stop below the 70% of the overall candle which can be assimilated to a Fibonacci level. Below this level it makes sense to stop the trade as the chance to recover the complete Candle is more than 60%
//Now we are in an open Long and can use all the mentioned Stop loss condition but still need a Take Profit condition
//The take profit condition is based on a RSI strategy consisting in taking profit as soon as the RSI come back from the overbought area (which is here defined as a rsi over 70) and reaching the 63.5 level to trigger the Take Profit
//This TP condition is only active when Long is active and when an entry value as been defined.
//Entry and SL level appreas as soon as a Long or short arrow signal does appears. The Take profit will be conidtioned to the RSI.
//The final step in the cycle is a reinitialization of all the values giving the possibility to detect and treat any long new signal coming from the Big Snapper signal.
RaenonX - Ampl TP/SLShows TP/SL points calculated using amplitude.
This takes the EMA of the HL or OC (configurable) difference, then multiplies it.
RSI_Boll-TP/SLThis strategy is originally "Bollinger + RSI , Double Strategy (by ChartArt)"
I added just TP/SL exit point, position direction selection(long, short or both) and time window into that strategy.
BTCUSDTPERP MEGABOT 60min [ALERTS VERSION]BINANCE:BTCUSDTPERP
Hello, this is my alerts version of BTCUSDTPERP MEGABOT 60min
THIS BOT IS ONLY FOR BTCUSDTPERP ON BINANCEFUTURES !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
This configs are only for this pair on this market,
It depends of volume , and others indicator
Bot is making amazing results at configs
TP - 4.5%
SL - 7%
Strategy using 4 indicators :
ADX
RSI
VOLUME
MACD
ADX - makes a solid view to trend without any scam wick :
Long only on green bars
Shorts only on red bars
That's helps my strategy to define a right trend
there is also a orange option for unidentified trends
RSI - value helps strategy to stop trade in right time
When RSI is overbought strategy don't open new longs
also when RSI is oversold strategy don't open new shorts
Volume - volume is the most important indicator for the strategy,
to avoid open trades on flat chart, new trades are open after a strong volume
wicks
MACD - this indicator is for define the trend
So the way this bot is working is simple
when every arguments are confirmed , then strategy open trades
Enjoy !!!
open range break out intraday with tpHI.. friends publishing ::********************************* open range break out intraday with tp********************************************
This indicator help intra day trader to when to short or long and when to take profit .this is basically chrismoody"s open rang breakout but i find it little confusing so i made some changes..i hope it will help traders...its automatically draw line on 15 min open and low on 5 min chart..so its save ur time ..and also added take profit line so we can book tp1 which is 0.77% and tp2 which is 1.6%...u can also change its setting as ur trading style.. u can also put alerts for for upper range and lower rage break out and tp1/tp2....so u don't need to sit infornt of ur terminal
Koala System EURUSD 15minToday I bring you one of the best systems I have found for 15min chart for EURUSD, can be adapted to other pairs aswell I suppose.
Its made of 4 SMA 3 6 9 50 and EMA 200.
It only makes 1 trade per day, in this case we have a risk % of our total eqquity, being the min 0.1 lots , can be changed tho .
We target TP/SL the same 1:1 rr, in this case I use 30 pips for both., that means I risk maximum 30$ out of a total of 1000 equity , per each trade , with 3%
Entry is simple : price is below all movings averages for sell or above for buy. At the same time we check that the ma's are in ascending or descending order.
The key here is patience, never make more than one trade per day.
System always close the trade at the end of london session. Also it only works, during the london session.
Enjoy it.
Simple and efficient 1h strategyThis strategy is made from a crossover of 2 ema : 4 and 8 in this case, together with a RSI of lenght 10 applied to hl2
The strategy is simple : we enter when we have a cross between the 2 ma's and rsi at the same time is in ascending or descending position crossing the middle line of 50.
For exit we have : at the end of a session( we trade only between london and newyork in this case, so we exit newyork), or through a tp/sl pip point system.
Hope you enjoy it.
Daytrade strategy RSI CCI EMA 4/8This strategy is designed for daytrade charts.
Its made from
EMA 4 / EMA 8 to check for crosses
RSI levels for overbough/oversold
CCI levels
For entry, we check first if the ema 4 crossed ema 8
Secondly we confirm by checking the level of RSI level
Finally we confirm with CCI level
If all of them are on the same page we enter.
For exit we have a fixed pip points system for TP/SL
MA * Fibo levels (auto)A few updates to the previous post.
In order to catch more exact points of TP and SL, the scrypt takes "high" as the source of SMA if the percentage is greater than 0 ( > 0), and "low" as the source when the given percentage is less than 0 ( < 0).
So there are two basic SMA line ( one with "high", the other one with "low"), and the other lines would be results of multiplying either the higher base or the lower one.
Good luck in trading!
If the scrypt was useful let me know!
Any feedbacks and ideas are welcomed!
Experimental Entry Interface (Buy Arrows with TP & SL)This script provides high probability entry points and includes Take Profit and Stop Loss targets.
It attempts to predict when the market conditions are set to move up, and prints long positions.
In addition to Long Entry Arrows, it will print Take Profit / Stop Loss targets.
This indicator is highly adjustable. Hence the name 'Experimental' in the title. Experiment with it to find the results you want.
Designed for use on the 1H timeframe in Forex, but could possibly be useful elsewhere. Do your own testing.
This indicator can repaint. It is best used with alerts set for once per bar close, so that your alerts do not repaint and your trades are solid.
Not ever signal is a winner. Backtest thoroughly. Adjust accordingly.
Arrows
Four sets of colored arrows are included.
๐ต ๐ถ Green and Blue Entry Arrows are formed when the market is in an uptrend, and has a momentary pullback.
๐ด ๐ท Yellow and Purple Entry Arrows are formed when the market is just starting to recover from being severely oversold.
Backtest Mode
Turn on Backtest Mode to easily see if an entry ended up as a winner or loser. A Take Profit and Stop Loss line will be drawn to show results.
Take Profit & Stop Loss Targets
You have two options for this.
Price will show you where your TP/SL exits should be placed. These values will show up under the arrow, based on your Risk/Reward ratio.
Pips are much more simple, and will only show you the market entry point and how many pips up/down to place your SL/TP. Warning: This is fixed at a 1:1 RRR .
Risk/Reward Adjustment
Each entry arrow color allows custom risk/reward ratio adjustment.
Dollar Amounts Displayed
Change your account value and leverage to see how much you would have won on each trade.
How to trade with it?
(Forex, 1H) Open the settings, and turn on all the arrow entries. Turn on Backtest mode to see how past trades would have played out. Turn on TakeProfit/StopLoss Targets to see where to set your targets, for each arrow. Set an alert to notify you once per candle close when there is an Entry. Trade happy!
Bill Williams Alligators are also included, if you want. Not necessary though. Some of the calculations depend on them for trend direction analysis.
red-sell green-buy TP and SLThis indicator is hybrid of some indicator with some modification
The hybrid is based on part of script of lazy bear TTM indicator together with part of script from modelius volume indicator . I cross them together and create this mutant
you can use ATR system , part of price system or traditional system . and for each time frame that you use set the TF =tf to same time frame or higher then the frame that you use
Its has many nice functions
inside also alerts and TP and SL function if you need such
I advise to you to play with settings in order to see what the vest result is
Volatility SL / TPBasic volatility Stop Loss / Take Profit you can use up to 3 TPs and one SL.
Currently, support the following modes.
- Multiple of Tradingview ATR
- Kases Dev-stop
[ALERTS]Super-Trend & SL/TP V3This simple script analyzes the trend in real time...
Alerts, SL, TP, bla, bla, bla...
[STUDY]HullMA OCC & SL/TP V3Another Open Close Cross. Now with Hull Moving Average: Alerts, SL TP, ...
Best results at 4h.
Enjoy!
TP-Plus IndicatorThis indicator calculates the current price range.
Calculate the slope or angle of the price velocity for both the fast and the slow period.
You can use it to spot the top and bottom of the range and wait for the price to break out of either level.
Once above the level top level or below bottom level, the price would move approximately the same distance as the height of the range.
TPS - FX TradeI based my strategy on the Lagging Span 2 line in the Ichimoku Cloud. I actually designed the strategy for the DAX Germany index 3 Minutes period, but you can use it on any instrument you want. I would like to point out some points that you should pay attention to when optimizing the strategy for the instrument you want to use.
Position Take Profit and Stop Loss levels are tick calculations. These values โโwill differ for each instrument. If you are trading in Forex, the values โโyou will write here should be starting from the numbers after the comma in the instrument value. For example, if you want to take profit at "200" points in DAX, you must write "20000" in the Long or Short Take Profit Score field, this applies to the Stop Loss Points, but if you want to take profit or stop loss at 200 points in UKOIL, you must write "200" in the entry part.
Golden Cross RSI Daily Helper (US Stocks)//@version=5
indicator("Golden Cross RSI Daily Helper (US Stocks)", overlay=true, timeframe="D", timeframe_gaps=true)
//========= ุงูุฅุนุฏุงุฏุงุช ุงูุฃุณุงุณูุฉ =========//
emaFastLen = input.int(50, "EMA ุณุฑูุน (ุงุชุฌุงู ูุตูุฑ ุงูู
ุฏู)")
emaSlowLen = input.int(200, "EMA ุจุทูุก (ุงุชุฌุงู ุทููู ุงูู
ุฏู)")
rsiLen = input.int(14, "ูุชุฑุฉ RSI")
rsiMin = input.float(40.0, "ุญุฏ RSI ุงูุฃุฏูู ููุฏุฎูู", 0.0, 100.0)
rsiMax = input.float(60.0, "ุญุฏ RSI ุงูุฃุนูู ููุฏุฎูู", 0.0, 100.0)
slBufferPerc = input.float(1.5, "ูุณุจุฉ ุงูุจูุฑ ูููู ุงูุฎุณุงุฑุฉ (%) ุฃุณูู/ุฃุนูู EMA200", 0.1, 5.0)
rrRatio = input.float(2.0, "ูุณุจุฉ ุงูุนุงุฆุฏ ุฅูู ุงูู
ุฎุงุทุฑุฉ (R:R)", 1.0, 5.0)
//========= ุญุณุงุจ ุงูู
ุคุดุฑุงุช =========//
emaFast = ta.ema(close, emaFastLen)
emaSlow = ta.ema(close, emaSlowLen)
rsiVal = ta.rsi(close, rsiLen)
// ุงุชุฌุงู ุงูุณูู
trendUp = emaFast > emaSlow
trendDown = emaFast < emaSlow
// ุงุฑุชุฏุงุฏ ุงูุณุนุฑ ู
ู EMA50 ุฃู EMA200 ุชูุฑูุจูุงู
bounceFromEmaFast = close > emaFast and low <= emaFast
bounceFromEmaSlow = close > emaSlow and low <= emaSlow
bounceLong = bounceFromEmaFast or bounceFromEmaSlow
bounceFromEmaFastShort = close < emaFast and high >= emaFast
bounceFromEmaSlowShort = close < emaSlow and high >= emaSlow
bounceShort = bounceFromEmaFastShort or bounceFromEmaSlowShort
// ููุชุฑ RSI
rsiOk = rsiVal >= rsiMin and rsiVal <= rsiMax
//========= ุดุฑูุท ุงูุฏุฎูู =========//
// ุดุฑุงุก
longSignal = trendUp and bounceLong and rsiOk
// ุจูุน
shortSignal = trendDown and bounceShort and rsiOk
//========= ุญุณุงุจ ููู ุงูุฎุณุงุฑุฉ ูุงูุฃูุฏุงู =========//
// ูุณุชุฎุฏู
ุณุนุฑ ุฅุบูุงู ุดู
ุนุฉ ุงูุฅุดุงุฑุฉ ูุณุนุฑ ุฏุฎูู ุงูุชุฑุงุถู
entryPriceLong = close
entryPriceShort = close
// ููู ุงูุฎุณุงุฑุฉ ุญุณุจ EMA200 + ุงูุจูุฑ
slLong = emaSlow * (1.0 - slBufferPerc / 100.0)
slShort = emaSlow * (1.0 + slBufferPerc / 100.0)
// ุงูู
ุณุงูุฉ ุจูู ุงูุฏุฎูู ูููู ุงูุฎุณุงุฑุฉ
riskLong = math.max(entryPriceLong - slLong, syminfo.mintick)
riskShort = math.max(slShort - entryPriceShort, syminfo.mintick)
// ูุฏู ุงูุฑุจุญ ุญุณุจ R:R
tpLong = entryPriceLong + rrRatio * riskLong
tpShort = entryPriceShort - rrRatio * riskShort
//========= ุงูุฑุณู
ุนูู ุงูุดุงุฑุช =========//
// ุฑุณู
ุงูู
ุชูุณุทุงุช
plot(emaFast, title="EMA 50", color=color.new(color.blue, 0), linewidth=2)
plot(emaSlow, title="EMA 200", color=color.new(color.orange, 0), linewidth=2)
// ุชูููู ุงูุฎูููุฉ ุญุณุจ ุงูุงุชุฌุงู
bgcolor(trendUp ? color.new(color.green, 92) : trendDown ? color.new(color.red, 92) : na)
// ุฅุดุงุฑุฉ ุดุฑุงุก
plotshape(
longSignal,
title = "ุฅุดุงุฑุฉ ุดุฑุงุก",
style = shape.triangleup,
location = location.belowbar,
size = size.large,
color = color.new(color.green, 0),
text = "BUY")
// ุฅุดุงุฑุฉ ุจูุน
plotshape(
shortSignal,
title = "ุฅุดุงุฑุฉ ุจูุน",
style = shape.triangledown,
location = location.abovebar,
size = size.large,
color = color.new(color.red, 0),
text = "SELL")
// ุฑุณู
SL ู TP ุนูุฏ ุธููุฑ ุงูุฅุดุงุฑุฉ
slPlotLong = longSignal ? slLong : na
tpPlotLong = longSignal ? tpLong : na
slPlotShort = shortSignal ? slShort : na
tpPlotShort = shortSignal ? tpShort : na
plot(slPlotLong, title="ููู ุฎุณุงุฑุฉ ุดุฑุงุก", color=color.new(color.red, 0), style=plot.style_linebr)
plot(tpPlotLong, title="ูุฏู ุดุฑุงุก", color=color.new(color.green, 0), style=plot.style_linebr)
plot(slPlotShort, title="ููู ุฎุณุงุฑุฉ ุจูุน", color=color.new(color.red, 0), style=plot.style_linebr)
plot(tpPlotShort, title="ูุฏู ุจูุน", color=color.new(color.green, 0), style=plot.style_linebr)
//========= ุฅุนุฏุงุฏ ุงูุชูุจููุงุช =========//
alertcondition(longSignal, title="ุชูุจูู ุฅุดุงุฑุฉ ุดุฑุงุก", message="ุฅุดุงุฑุฉ ุดุฑุงุก: ุชุฑูุฏ ุตุงุนุฏ + ุงุฑุชุฏุงุฏ ู
ู EMA + RSI ูู ุงูู
ูุทูุฉ ุงูู
ุณู
ูุญุฉ.")
alertcondition(shortSignal, title="ุชูุจูู ุฅุดุงุฑุฉ ุจูุน", message="ุฅุดุงุฑุฉ ุจูุน: ุชุฑูุฏ ูุงุจุท + ุงุฑุชุฏุงุฏ ู
ู EMA + RSI ูู ุงูู
ูุทูุฉ ุงูู
ุณู
ูุญุฉ.")
ATR ZigZag BreakoutATR ZigZag Breakout
This strategy uses my ATR ZigZag indicator (powered by the ZigZagCore library) to scalp breakouts at volatility-filtered highs and lows.
Everyone knows stops cluster around clear swing highs and lows. Breakout traders often pile in there, too. These levels are predictable areas where aggressive orders hit the tape. The idea here is simple:
โ Let ATR ZigZag define clean, volatility-filtered pivots
โ Arm a stop market order at those pivots
โ Join the breakout when the crowd hits the level
The key to greater success in this simple strategy lies in the ZigZag. Because the pivots are filtered by ATR instead of fixed bar counts or fractals, the levels tend to be more meaningful and less noisy.
This approach is especially suited for intraday trading on volatile instruments (e.g., NQ, GC, liquid crypto pairs).
How It Works
1. Pivot detection
The ATR ZigZag uses an ATR-based threshold to confirm swing highs and lows. Only when price has moved far enough in the opposite direction does a pivot become โofficial.โ
2. Candidate breakout level
When a new swing direction is detected and the most recent high/low has not yet been broken in the current leg, the strategy arms a stop market order at that pivot.
โข Long candidate โ most recent swing high
โข Short candidate โ most recent swing low
These โcandidate tradesโ are shown as dotted lines.
3. Entry, SL, and TP
If price breaks through the level, the stop order is filled and a bracket is placed:
โข Stop loss = ATR ร SL multiplier
โข Take profit = SL distance ร RR multiplier
Once a level has traded, it is not reused in the same swing leg.
4. Cancel & rotate
If the market reverses and forms a new swing in the opposite direction before the level is hit, the pending order is cancelled and a new candidate is considered in the new direction.
Additional Features
โข Optional session filter for backtesting specific trading hours
PineConnectorLibrary "PineConnector"
This library is a comprehensive alert webhook text generator for PineConnector. It contains every possible alert syntax variation from the documentation, along with some debugging functions.
To use it, just import the library (eg. "import ZenAndTheArtOfTrading/PineConnector/1 as pc") and use pc.buy(licenseID) to send an alert off to PineConnector - assuming all your webhooks etc are set up correctly.
View the PineConnector documentation for more information on how to send the commands you're looking to send (all of this library's function names match the documentation).
all()
โโUsage: pc.buy(pc_id, freq=pc.all())
โโReturns: "all"
once_per_bar()
โโUsage: pc.buy(pc_id, freq=pc.once_per_bar())
โโReturns: "once_per_bar"
once_per_bar_close()
โโUsage: pc.buy(pc_id, freq=pc.once_per_bar_close())
โโReturns: "once_per_bar_close"
na0(value)
โโChecks if given value is either 'na' or 0. Useful for streamlining scripts with float user setting inputs which default values to 0 since na is unavailable as a user input default.
โโParameters:
โโโโ value (float) : The value to check
โโReturns: True if the given value is 0 or na
getDecimals()
โโCalculates how many decimals are on the quote price of the current market.
โโReturns: The current decimal places on the market quote price
truncate(number, decimals)
โโTruncates the given number. Required params: mumber.
โโParameters:
โโโโ number (float) : Number to truncate
โโโโ decimals (int) : Decimal places to cut down to
โโReturns: The input number, but as a string truncated to X decimals
getPipSize(multiplier)
โโCalculates the pip size of the current market.
โโParameters:
โโโโ multiplier (int) : The mintick point multiplier (1 by default, 10 for FX/Crypto/CFD but can be used to override when certain markets require)
โโReturns: The pip size for the current market
toWhole(number)
โโConverts pips into whole numbers. Required params: number.
โโParameters:
โโโโ number (float) : The pip number to convert into a whole number
โโReturns: The converted number
toPips(number)
โโConverts whole numbers back into pips. Required params: number.
โโParameters:
โโโโ number (float) : The whole number to convert into pips
โโReturns: The converted number
debug(txt, tooltip, displayLabel)
โโPrints to console and generates a debug label with the given text. Required params: txt.
โโParameters:
โโโโ txt (string) : Text to display
โโโโ tooltip (string) : Tooltip to display (optional)
โโโโ displayLabel (bool) : Turns on/off chart label (default: off)
โโReturns: Nothing
order(licenseID, command, symbol, parameters, accfilter, comment, secret, freq, debug)
โโGenerates an alert string. Required params: licenseID, command.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ command (string) : Command to send
โโโโ symbol (string) : The symbol to trigger this order on
โโโโ parameters (string) : Other optional parameters to include
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: An alert string with valid PC syntax based on supplied parameters
market_order(licenseID, buy, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโGenerates a market entry alert with relevant syntax commands. Required params: licenseID, buy, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ buy (bool) : true=buy/long, false=sell/short
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A market order alert string with valid PC syntax based on supplied parameters
buy(licenseID, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโGenerates a market buy alert with relevant syntax commands. Required params: licenseID, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A market order alert string with valid PC syntax based on supplied parameters
sell(licenseID, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโGenerates a market sell alert with relevant syntax commands. Required params: licenseID, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A market order alert string with valid PC syntax based on supplied parameters
closeall(licenseID, comment, secret, freq, debug)
โโCloses all open trades at market regardless of symbol. Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
closealleaoff(licenseID, comment, secret, freq, debug)
โโCloses all open trades at market regardless of symbol, and turns the EA off. Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
closelong(licenseID, symbol, comment, secret, freq, debug)
โโCloses all long trades at market for the given symbol. Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
closeshort(licenseID, symbol, comment, secret, freq, debug)
โโCloses all open short trades at market for the given symbol. Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
closelongshort(licenseID, symbol, comment, secret, freq, debug)
โโCloses all open trades at market for the given symbol. Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
closelongbuy(licenseID, risk, symbol, comment, secret, freq, debug)
โโClose all long positions and open a new long at market for the given symbol with given risk/contracts. Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ risk (float) : Risk or contracts (according to EA settings)
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
closeshortsell(licenseID, risk, symbol, comment, secret, freq, debug)
โโClose all short positions and open a new short at market for the given symbol with given risk/contracts. Required params: licenseID, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ risk (float) : Risk or contracts (according to EA settings)
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
newsltplong(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
โโUpdates the stop loss and/or take profit of any open long trades on the given symbol with the given values. Required params: licenseID, sl and/or tp.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ sl (float) : Stop loss pips or price (according to EA settings)
โโโโ tp (float) : Take profit pips or price (according to EA settings)
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
newsltpshort(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
โโUpdates the stop loss and/or take profit of any open short trades on the given symbol with the given values. Required params: licenseID, sl and/or tp.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ sl (float) : Stop loss pips or price (according to EA settings)
โโโโ tp (float) : Take profit pips or price (according to EA settings)
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
closelongpct(licenseID, symbol, comment, secret, freq, debug)
โโClose a percentage of open long positions (according to EA settings). Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
closeshortpct(licenseID, symbol, comment, secret, freq, debug)
โโClose a percentage of open short positions (according to EA settings). Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
closelongvol(licenseID, risk, symbol, comment, secret, freq, debug)
โโClose all open long contracts on the current symbol until the given risk value is remaining. Required params: licenseID, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ risk (float) : The quantity to leave remaining
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
closeshortvol(licenseID, risk, symbol, comment, secret, freq, debug)
โโClose all open short contracts on the current symbol until the given risk value is remaining. Required params: licenseID, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ risk (float) : The quantity to leave remaining
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
limit_order(licenseID, buy, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโGenerates a limit order alert with relevant syntax commands. Required params: licenseID, buy, price, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ buy (bool) : true=buy/long, false=sell/short
โโโโ price (float) : Price or pips to set limit order (according to EA settings)
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A limit order alert string with valid PC syntax based on supplied parameters
buylimit(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโGenerates a buylimit order alert with relevant syntax commands. Required params: licenseID, price, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ price (float) : Price or pips to set limit order (according to EA settings)
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A limit order alert string with valid PC syntax based on supplied parameters
selllimit(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโGenerates a selllimit order alert with relevant syntax commands. Required params: licenseID, price, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ price (float) : Price or pips to set limit order (according to EA settings)
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A limit order alert string with valid PC syntax based on supplied parameters
stop_order(licenseID, buy, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโGenerates a stop order alert with relevant syntax commands. Required params: licenseID, buy, price, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ buy (bool) : true=buy/long, false=sell/short
โโโโ price (float) : Price or pips to set limit order (according to EA settings)
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A stop order alert string with valid PC syntax based on supplied parameters
buystop(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโGenerates a buystop order alert with relevant syntax commands. Required params: licenseID, price, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ price (float) : Price or pips to set limit order (according to EA settings)
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A stop order alert string with valid PC syntax based on supplied parameters
sellstop(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโGenerates a sellstop order alert with relevant syntax commands. Required params: licenseID, price, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ price (float) : Price or pips to set limit order (according to EA settings)
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A stop order alert string with valid PC syntax based on supplied parameters
cancel_neworder(licenseID, order, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโCancel + place new order template function.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ order (string) : Cancel order type
โโโโ price (float) : Price or pips to set limit order (according to EA settings)
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A stop order alert string with valid PC syntax based on supplied parameters
cancellongbuystop(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโCancels all long orders with the specified symbol and places a new buystop order. Required params: licenseID, price, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ price (float) : Price or pips to set limit order (according to EA settings)
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A stop order alert string with valid PC syntax based on supplied parameters
cancellongbuylimit(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโCancels all long orders with the specified symbol and places a new buylimit order. Required params: licenseID, price, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ price (float) : Price or pips to set limit order (according to EA settings)
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A stop order alert string with valid PC syntax based on supplied parameters
cancelshortsellstop(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโCancels all short orders with the specified symbol and places a sellstop order. Required params: licenseID, price, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ price (float) : Price or pips to set limit order (according to EA settings)
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A stop order alert string with valid PC syntax based on supplied parameters
cancelshortselllimit(licenseID, price, risk, sl, tp, betrigger, beoffset, spread, trailtrig, traildist, trailstep, atrtimeframe, atrperiod, atrmultiplier, atrshift, atrtrigger, symbol, accfilter, comment, secret, freq, debug)
โโCancels all short orders with the specified symbol and places a selllimit order. Required params: licenseID, price, risk.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ price (float) : Price or pips to set limit order (according to EA settings)
โโโโ risk (float) : Risk quantity (according to EA settings)
โโโโ sl (float) : Stop loss distance in pips or price
โโโโ tp (float) : Take profit distance in pips or price
โโโโ betrigger (float) : Breakeven will be activated after the position gains this number of pips
โโโโ beoffset (float) : Offset from entry price. This is the amount of pips you'd like to protect
โโโโ spread (float) : Enter the position only if the spread is equal or less than the specified value in pips
โโโโ trailtrig (float) : Trailing stop-loss will be activated after a trade gains this number of pips
โโโโ traildist (float) : Distance of the trailing stop-loss from current price
โโโโ trailstep (float) : Moves trailing stop-loss once price moves to favourable by a specified number of pips
โโโโ atrtimeframe (int) : ATR Trailing Stop timeframe, only updates once per bar close. Options: 1, 5, 15, 30, 60, 240, 1440
โโโโ atrperiod (int) : ATR averaging period
โโโโ atrmultiplier (float) : Multiple of ATR to utilise in the new SL computation, default = 1
โโโโ atrshift (int) : Relative shift of price information, 0 uses latest candle, 1 uses second last, etc. Default = 0
โโโโ atrtrigger (int) : Activate the trigger of ATR Trailing after market moves favourably by a number of pips. Default = 0 (instant)
โโโโ symbol (string) : The symbol to trigger this order on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment (maximum 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A stop order alert string with valid PC syntax based on supplied parameters
cancellong(licenseID, symbol, accfilter, comment, secret, freq, debug)
โโCancels all pending long orders with the specified symbol. Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A cancel long alert command
cancelshort(licenseID, symbol, accfilter, comment, secret, freq, debug)
โโCancels all pending short orders with the specified symbol. Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: A cancel short alert command
newsltpbuystop(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
โโUpdates the stop loss and/or take profit of any pending buy stop orders on the given symbol. Required params: licenseID, sl and/or tp.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ sl (float) : Stop loss pips or price (according to EA settings)
โโโโ tp (float) : Take profit pips or price (according to EA settings)
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
newsltpbuylimit(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
โโUpdates the stop loss and/or take profit of any pending buy limit orders on the given symbol. Required params: licenseID, sl and/or tp.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ sl (float) : Stop loss pips or price (according to EA settings)
โโโโ tp (float) : Take profit pips or price (according to EA settings)
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
newsltpsellstop(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
โโUpdates the stop loss and/or take profit of any pending sell stop orders on the given symbol. Required params: licenseID, sl and/or tp.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ sl (float) : Stop loss pips or price (according to EA settings)
โโโโ tp (float) : Take profit pips or price (according to EA settings)
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
newsltpselllimit(licenseID, sl, tp, symbol, accfilter, comment, secret, freq, debug)
โโUpdates the stop loss and/or take profit of any pending sell limit orders on the given symbol. Required params: licenseID, sl and/or tp.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ sl (float) : Stop loss pips or price (according to EA settings)
โโโโ tp (float) : Take profit pips or price (according to EA settings)
โโโโ symbol (string) : Symbol to act on (defaults to current symbol)
โโโโ accfilter (float) : Optional minimum account balance filter
โโโโ comment (string) : Optional comment to include (max 20 characters)
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
eaoff(licenseID, secret, freq, debug)
โโTurns the EA off. Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
eaon(licenseID, secret, freq, debug)
โโTurns the EA on. Required params: licenseID.
โโParameters:
โโโโ licenseID (string) : Your PC license ID
โโโโ secret (string) : Optional secret key (must be enabled in dashboard)
โโโโ freq (string) : Alert frequency. Default = "all", options = "once_per_bar", "once_per_bar_close" and "none"
โโโโ debug (bool) : Turns on/off debug label
โโReturns: The required alert syntax as a string
BOCS Channel Scalper Indicator - Mean Reversion Alert System# BOCS Channel Scalper Indicator - Mean Reversion Alert System
## WHAT THIS INDICATOR DOES:
This is a mean reversion trading indicator that identifies consolidation channels through volatility analysis and generates alert signals when price enters entry zones near channel boundaries. **This indicator version is designed for manual trading with comprehensive alert functionality.** Unlike automated strategies, this tool sends notifications (via popup, email, SMS, or webhook) when trading opportunities occur, allowing you to manually review and execute trades. The system assumes price will revert to the channel mean, identifying scalp opportunities as price reaches extremes and preparing to bounce back toward center.
## INDICATOR VS STRATEGY - KEY DISTINCTION:
**This is an INDICATOR with alerts, not an automated strategy.** It does not execute trades automatically. Instead, it:
- Displays visual signals on your chart when entry conditions are met
- Sends customizable alerts to your device/email when opportunities arise
- Shows TP/SL levels for reference but does not place orders
- Requires you to manually enter and exit positions based on signals
- Works with all TradingView subscription levels (alerts included on all plans)
**For automated trading with backtesting**, use the strategy version. For manual control with notifications, use this indicator version.
## ALERT CAPABILITIES:
This indicator includes four distinct alert conditions that can be configured independently:
**1. New Channel Formation Alert**
- Triggers when a fresh BOCS channel is identified
- Message: "New BOCS channel formed - potential scalp setup ready"
- Use this to prepare for upcoming trading opportunities
**2. Long Scalp Entry Alert**
- Fires when price touches the long entry zone
- Message includes current price, calculated TP, and SL levels
- Notification example: "LONG scalp signal at 24731.75 | TP: 24743.2 | SL: 24716.5"
**3. Short Scalp Entry Alert**
- Fires when price touches the short entry zone
- Message includes current price, calculated TP, and SL levels
- Notification example: "SHORT scalp signal at 24747.50 | TP: 24735.0 | SL: 24762.75"
**4. Any Entry Signal Alert**
- Combined alert for both long and short entries
- Use this if you want a single alert stream for all opportunities
- Message: "BOCS Scalp Entry: at "
**Setting Up Alerts:**
1. Add indicator to chart and configure settings
2. Click the Alert (โฐ) button in TradingView toolbar
3. Select "BOCS Channel Scalper" from condition dropdown
4. Choose desired alert type (Long, Short, Any, or Channel Formation)
5. Set "Once Per Bar Close" to avoid false signals during bar formation
6. Configure delivery method (popup, email, webhook for automation platforms)
7. Save alert - it will fire automatically when conditions are met
**Alert Message Placeholders:**
Alerts use TradingView's dynamic placeholder system:
- {{ticker}} = Symbol name (e.g., NQ1!)
- {{close}} = Current price at signal
- {{plot_1}} = Calculated take profit level
- {{plot_2}} = Calculated stop loss level
These placeholders populate automatically, creating detailed notification messages without manual configuration.
## KEY DIFFERENCE FROM ORIGINAL BOCS:
**This indicator is designed for traders seeking higher trade frequency.** The original BOCS indicator trades breakouts OUTSIDE channels, waiting for price to escape consolidation before entering. This scalper version trades mean reversion INSIDE channels, entering when price reaches channel extremes and betting on a bounce back to center. The result is significantly more trading opportunities:
- **Original BOCS**: 1-3 signals per channel (only on breakout)
- **Scalper Indicator**: 5-15+ signals per channel (every touch of entry zones)
- **Trade Style**: Mean reversion vs trend following
- **Hold Time**: Seconds to minutes vs minutes to hours
- **Best Markets**: Ranging/choppy conditions vs trending breakouts
This makes the indicator ideal for active day traders who want continuous alert opportunities within consolidation zones rather than waiting for breakout confirmation. However, increased signal frequency also means higher potential commission costs and requires disciplined trade selection when acting on alerts.
## TECHNICAL METHODOLOGY:
### Price Normalization Process:
The indicator normalizes price data to create consistent volatility measurements across different instruments and price levels. It calculates the highest high and lowest low over a user-defined lookback period (default 100 bars). Current close price is normalized using: (close - lowest_low) / (highest_high - lowest_low), producing values between 0 and 1 for standardized volatility analysis.
### Volatility Detection:
A 14-period standard deviation is applied to the normalized price series to measure price deviation from the mean. Higher standard deviation values indicate volatility expansion; lower values indicate consolidation. The indicator uses ta.highestbars() and ta.lowestbars() to identify when volatility peaks and troughs occur over the detection period (default 14 bars).
### Channel Formation Logic:
When volatility crosses from a high level to a low level (ta.crossover(upper, lower)), a consolidation phase begins. The indicator tracks the highest and lowest prices during this period, which become the channel boundaries. Minimum duration of 10+ bars is required to filter out brief volatility spikes. Channels are rendered as box objects with defined upper and lower boundaries, with colored zones indicating entry areas.
### Entry Signal Generation:
The indicator uses immediate touch-based entry logic. Entry zones are defined as a percentage from channel edges (default 20%):
- **Long Entry Zone**: Bottom 20% of channel (bottomBound + channelRange ร 0.2)
- **Short Entry Zone**: Top 20% of channel (topBound - channelRange ร 0.2)
Long signals trigger when candle low touches or enters the long entry zone. Short signals trigger when candle high touches or enters the short entry zone. Visual markers (arrows and labels) appear on chart, and configured alerts fire immediately.
### Cooldown Filter:
An optional cooldown period (measured in bars) prevents alert spam by enforcing minimum spacing between consecutive signals. If cooldown is set to 3 bars, no new long alert will fire until 3 bars after the previous long signal. Long and short cooldowns are tracked independently, allowing both directions to signal within the same period.
### ATR Volatility Filter:
The indicator includes a multi-timeframe ATR filter to avoid alerts during low-volatility conditions. Using request.security(), it fetches ATR values from a specified timeframe (e.g., 1-minute ATR while viewing 5-minute charts). The filter compares current ATR to a user-defined minimum threshold:
- If ATR โฅ threshold: Alerts enabled
- If ATR < threshold: No alerts fire
This prevents notifications during dead zones where mean reversion is unreliable due to insufficient price movement. The ATR status is displayed in the info table with visual confirmation (โ or โ).
### Take Profit Calculation:
Two TP methods are available:
**Fixed Points Mode**:
- Long TP = Entry + (TP_Ticks ร syminfo.mintick)
- Short TP = Entry - (TP_Ticks ร syminfo.mintick)
**Channel Percentage Mode**:
- Long TP = Entry + (ChannelRange ร TP_Percent)
- Short TP = Entry - (ChannelRange ร TP_Percent)
Default 50% targets the channel midline, a natural mean reversion target. These levels are displayed as visual lines with labels and included in alert messages for reference when manually placing orders.
### Stop Loss Placement:
Stop losses are calculated just outside the channel boundary by a user-defined tick offset:
- Long SL = ChannelBottom - (SL_Offset_Ticks ร syminfo.mintick)
- Short SL = ChannelTop + (SL_Offset_Ticks ร syminfo.mintick)
This logic assumes channel breaks invalidate the mean reversion thesis. SL levels are displayed on chart and included in alert notifications as suggested stop placement.
### Channel Breakout Management:
Channels are removed when price closes more than 10 ticks outside boundaries. This tolerance prevents premature channel deletion from minor breaks or wicks, allowing the mean reversion setup to persist through small boundary violations.
## INPUT PARAMETERS:
### Channel Settings:
- **Nested Channels**: Allow multiple overlapping channels vs single channel
- **Normalization Length**: Lookback for high/low calculation (1-500, default 100)
- **Box Detection Length**: Period for volatility detection (1-100, default 14)
### Scalping Settings:
- **Enable Long Scalps**: Toggle long alert generation on/off
- **Enable Short Scalps**: Toggle short alert generation on/off
- **Entry Zone % from Edge**: Size of entry zone (5-50%, default 20%)
- **SL Offset (Ticks)**: Distance beyond channel for stop (1+, default 5)
- **Cooldown Period (Bars)**: Minimum spacing between alerts (0 = no cooldown)
### ATR Filter:
- **Enable ATR Filter**: Toggle volatility filter on/off
- **ATR Timeframe**: Source timeframe for ATR (1, 5, 15, 60 min, etc.)
- **ATR Length**: Smoothing period (1-100, default 14)
- **Min ATR Value**: Threshold for alert enablement (0.1+, default 10.0)
### Take Profit Settings:
- **TP Method**: Choose Fixed Points or % of Channel
- **TP Fixed (Ticks)**: Static distance in ticks (1+, default 30)
- **TP % of Channel**: Dynamic target as channel percentage (10-100%, default 50%)
### Appearance:
- **Show Entry Zones**: Toggle zone labels on channels
- **Show Info Table**: Display real-time indicator status
- **Table Position**: Corner placement (Top Left/Right, Bottom Left/Right)
- **Long Color**: Customize long signal color (default: darker green for readability)
- **Short Color**: Customize short signal color (default: red)
- **TP/SL Colors**: Customize take profit and stop loss line colors
- **Line Length**: Visual length of TP/SL reference lines (5-200 bars)
## VISUAL INDICATORS:
- **Channel boxes** with semi-transparent fill showing consolidation zones
- **Colored entry zones** labeled "LONG ZONE โฒ" and "SHORT ZONE โผ"
- **Entry signal arrows** below/above bars marking long/short alerts
- **TP/SL reference lines** with emoji labels (โ Entry, ๐ฏ TP, ๐ SL)
- **Info table** showing channel status, last signal, entry/TP/SL prices, risk/reward ratio, and ATR filter status
- **Visual confirmation** when alerts fire via on-chart markers synchronized with notifications
## HOW TO USE:
### For 1-3 Minute Scalping with Alerts (NQ/ES):
- ATR Timeframe: "1" (1-minute)
- ATR Min Value: 10.0 (for NQ), adjust per instrument
- Entry Zone %: 20-25%
- TP Method: Fixed Points, 20-40 ticks
- SL Offset: 5-10 ticks
- Cooldown: 2-3 bars to reduce alert spam
- **Alert Setup**: Configure "Any Entry Signal" for combined long/short notifications
- **Execution**: When alert fires, verify chart visuals, then manually place limit order at entry zone with provided TP/SL levels
### For 5-15 Minute Day Trading with Alerts:
- ATR Timeframe: "5" or match chart
- ATR Min Value: Adjust to instrument (test 8-15 for NQ)
- Entry Zone %: 20-30%
- TP Method: % of Channel, 40-60%
- SL Offset: 5-10 ticks
- Cooldown: 3-5 bars
- **Alert Setup**: Configure separate "Long Scalp Entry" and "Short Scalp Entry" alerts if you trade directionally based on bias
- **Execution**: Review channel structure on alert, confirm ATR filter shows โ, then enter manually
### For 30-60 Minute Swing Scalping with Alerts:
- ATR Timeframe: "15" or "30"
- ATR Min Value: Lower threshold for broader market
- Entry Zone %: 25-35%
- TP Method: % of Channel, 50-70%
- SL Offset: 10-15 ticks
- Cooldown: 5+ bars or disable
- **Alert Setup**: Use "New Channel Formation" to prepare for setups, then "Any Entry Signal" for execution alerts
- **Execution**: Larger timeframes allow more analysis time between alert and entry
### Webhook Integration for Semi-Automation:
- Configure alert webhook URL to connect with platforms like TradersPost, TradingView Paper Trading, or custom automation
- Alert message includes all necessary order parameters (direction, entry, TP, SL)
- Webhook receives structured data when signal fires
- External platform can auto-execute based on alert payload
- Still maintains manual oversight vs full strategy automation
## USAGE CONSIDERATIONS:
- **Manual Discipline Required**: Alerts provide opportunities but execution requires judgment. Not all alerts should be taken - consider market context, trend, and channel quality
- **Alert Timing**: Alerts fire on bar close by default. Ensure "Once Per Bar Close" is selected to avoid false signals during bar formation
- **Notification Delivery**: Mobile/email alerts may have 1-3 second delay. For immediate execution, use desktop popups or webhook automation
- **Cooldown Necessity**: Without cooldown, rapidly touching price action can generate excessive alerts. Start with 3-bar cooldown and adjust based on alert volume
- **ATR Filter Impact**: Enabling ATR filter dramatically reduces alert count but improves quality. Track filter status in info table to understand when you're receiving fewer alerts
- **Commission Awareness**: High alert frequency means high potential trade count. Calculate if your commission structure supports frequent scalping before acting on all alerts
## COMPATIBLE MARKETS:
Works on any instrument with price data including stock indices (NQ, ES, YM, RTY), individual stocks, forex pairs (EUR/USD, GBP/USD), cryptocurrency (BTC, ETH), and commodities. Volume-based features are not included in this indicator version. Multi-timeframe ATR requires higher-tier TradingView subscription for request.security() functionality on timeframes below chart timeframe.
## KNOWN LIMITATIONS:
- **Indicator does not execute trades** - alerts are informational only; you must manually place all orders
- **Alert delivery depends on TradingView infrastructure** - delays or failures possible during platform issues
- **No position tracking** - indicator doesn't know if you're in a trade; you must manage open positions independently
- **TP/SL levels are reference only** - you must manually set these on your broker platform; they are not live orders
- **Immediate touch entry can generate many alerts** in choppy zones without adequate cooldown
- **Channel deletion at 10-tick breaks** may be too aggressive or lenient depending on instrument tick size
- **ATR filter from lower timeframes** requires TradingView Premium/Pro+ for request.security()
- **Mean reversion logic fails** in strong breakout scenarios - alerts will fire but trades may hit stops
- **No partial closing capability** - full position management is manual; you determine scaling out
- **Alerts do not account for gaps** or overnight price changes; morning alerts may be stale
## RISK DISCLOSURE:
Trading involves substantial risk of loss. This indicator provides signals for educational and informational purposes only and does not constitute financial advice. Past performance does not guarantee future results. Mean reversion strategies can experience extended drawdowns during trending markets. Alerts are not guaranteed to be profitable and should be combined with your own analysis. Stop losses may not fill at intended levels during extreme volatility or gaps. Never trade with capital you cannot afford to lose. Consider consulting a licensed financial advisor before making trading decisions. Always verify alerts against current market conditions before executing trades manually.
## ACKNOWLEDGMENT & CREDITS:
This indicator is built upon the channel detection methodology created by **AlgoAlpha** in the "Smart Money Breakout Channels" indicator. Full credit and appreciation to AlgoAlpha for pioneering the normalized volatility approach to identifying consolidation patterns. The core channel formation logic using normalized price standard deviation is AlgoAlpha's original contribution to the TradingView community.
Enhancements to the original concept include: mean reversion entry logic (vs breakout), immediate touch-based alert generation, comprehensive alert condition system with customizable notifications, multi-timeframe ATR volatility filtering, cooldown period for alert management, dual TP methods (fixed points vs channel percentage), visual TP/SL reference lines, and real-time status monitoring table. This indicator version is specifically designed for manual traders who prefer alert-based decision making over automated execution.
Nef33 Forex & Crypto Trading Signals PRO
1. Understanding the Indicator's Context
The indicator generates signals based on confluence (trend, volume, key zones, etc.), but it does not include predefined SL or TP levels. To establish them, we must:
Use dynamic or static support/resistance levels already present in the script.
Incorporate volatility (such as ATR) to adjust the levels based on market conditions.
Define a risk/reward ratio (e.g., 1:2).
2. Options for Determining SL and TP
Below, I provide several ideas based on the tools available in the script:
Stop Loss (SL)
The SL should protect you from adverse movements. You can base it on:
ATR (Volatility): Use the smoothed ATR (atr_smooth) multiplied by a factor (e.g., 1.5 or 2) to set a dynamic SL.
Buy: SL = Entry Price - (atr_smooth * atr_mult).
Sell: SL = Entry Price + (atr_smooth * atr_mult).
Key Zones: Place the SL below a support (for buys) or above a resistance (for sells), using Order Blocks, Fair Value Gaps, or Liquidity Zones.
Buy: SL below the nearest ob_lows or fvg_lows.
Sell: SL above the nearest ob_highs or fvg_highs.
VWAP: Use the daily VWAP (vwap_day) as a critical level.
Buy: SL below vwap_day.
Sell: SL above vwap_day.
Take Profit (TP)
The TP should maximize profits. You can base it on:
Risk/Reward Ratio: Multiply the SL distance by a factor (e.g., 2 or 3).
Buy: TP = Entry Price + (SL Distance * 2).
Sell: TP = Entry Price - (SL Distance * 2).
Key Zones: Target the next resistance (for buys) or support (for sells).
Buy: TP at the next ob_highs, fvg_highs, or liq_zone_high.
Sell: TP at the next ob_lows, fvg_lows, or liq_zone_low.
Ichimoku: Use the cloud levels (Senkou Span A/B) as targets.
Buy: TP at senkou_span_a or senkou_span_b (whichever is higher).
Sell: TP at senkou_span_a or senkou_span_b (whichever is lower).
3. Practical Implementation
Since the script does not automatically draw SL/TP, you can:
Calculate them manually: Observe the chart and use the levels mentioned.
Modify the code: Add SL/TP as labels (label.new) at the moment of the signal.
Hereโs an example of how to modify the code to display SL and TP based on ATR with a 1:2 risk/reward ratio:
Modified Code (Signals Section)
Find the lines where the signals (trade_buy and trade_sell) are generated and add the following:
pinescript
// Calculate SL and TP based on ATR
atr_sl_mult = 1.5 // Multiplier for SL
atr_tp_mult = 3.0 // Multiplier for TP (1:2 ratio)
sl_distance = atr_smooth * atr_sl_mult
tp_distance = atr_smooth * atr_tp_mult
if trade_buy
entry_price = close
sl_price = entry_price - sl_distance
tp_price = entry_price + tp_distance
label.new(bar_index, low, "Buy: " + str.tostring(math.round(bull_conditions, 1)), color=color.green, textcolor=color.white, style=label.style_label_up, size=size.tiny)
label.new(bar_index, sl_price, "SL: " + str.tostring(math.round(sl_price, 2)), color=color.red, textcolor=color.white, style=label.style_label_down, size=size.tiny)
label.new(bar_index, tp_price, "TP: " + str.tostring(math.round(tp_price, 2)), color=color.blue, textcolor=color.white, style=label.style_label_up, size=size.tiny)
if trade_sell
entry_price = close
sl_price = entry_price + sl_distance
tp_price = entry_price - tp_distance
label.new(bar_index, high, "Sell: " + str.tostring(math.round(bear_conditions, 1)), color=color.red, textcolor=color.white, style=label.style_label_down, size=size.tiny)
label.new(bar_index, sl_price, "SL: " + str.tostring(math.round(sl_price, 2)), color=color.red, textcolor=color.white, style=label.style_label_up, size=size.tiny)
label.new(bar_index, tp_price, "TP: " + str.tostring(math.round(tp_price, 2)), color=color.blue, textcolor=color.white, style=label.style_label_down, size=size.tiny)
Code Explanation
SL: Calculated by subtracting/adding sl_distance to the entry price (close) depending on whether itโs a buy or sell.
TP: Calculated with a double distance (tp_distance) for a 1:2 risk/reward ratio.
Visualization: Labels are added to the chart to display SL (red) and TP (blue).
4. Practical Strategy Without Modifying the Code
If you donโt want to modify the script, follow these steps manually:
Entry: Take the trade_buy or trade_sell signal.
SL: Check the smoothed ATR (atr_smooth) on the chart or calculate a fixed level (e.g., 1.5 times the ATR). Also, review nearby key zones (OB, FVG, VWAP).
TP: Define a target based on the next key zone or multiply the SL distance by 2 or 3.
Example:
Buy at 100, ATR = 2.
SL = 100 - (2 * 1.5) = 97.
TP = 100 + (2 * 3) = 106.
5. Recommendations
Test in Demo: Apply this logic in a demo account to adjust the multipliers (atr_sl_mult, atr_tp_mult) based on the market (forex or crypto).
Combine with Zones: If the ATR-based SL is too wide, use the nearest OB or FVG as a reference.
Risk/Reward Ratio: Adjust the TP based on your tolerance (1:1, 1:2, 1:3)






















