ٹرینڈ بریک آؤٹ ٹریڈنگ کی درست حکمت عملی

مصنف:چاؤ ژانگ، تاریخ: 2023-11-02 16:26:22
ٹیگز:

img

جائزہ

درست ٹرینڈ بریکآؤٹ ٹریڈنگ حکمت عملی ٹرینڈ بریکآؤٹس کو درست طریقے سے پکڑنے کے لئے ٹرینڈ اشارے اور مخصوص موم بتیوں کے نمونوں کا استعمال کرتی ہے۔ یہ ٹرینڈ کی سمت کا تعین کرنے کے لئے حرکت پذیر اوسط ، اوور بُک اور اوور سیل سطحوں کا اندازہ لگانے کے لئے آر ایس آئی ، اور بریکآؤٹ انٹری پوائنٹس کی نشاندہی کرنے کے لئے جدید موم بتیوں کے نمونوں کو جوڑتا ہے ، جس سے بڑے پیمانے پر منافع کے لئے مناسب لمحات میں بریکآؤٹ ٹریڈنگ کے لئے ٹرینڈ کی عین مطابق نشاندہی کی جاسکتی ہے۔

حکمت عملی منطق

  1. رجحان کی سمت کی وضاحت کرنے کے لئے 8 پیریڈ ای ایم اے اور 80 پیریڈ ای ایم اے کا استعمال کریں۔ 80 پیریڈ ای ایم اے سے اوپر 8 پیریڈ ای ایم اے اپ ٹرینڈ کی نشاندہی کرتا ہے ، اور اس کے برعکس ڈاؤن ٹرینڈ کے لئے۔ صرف اس وقت تجارتی سگنلز پر غور کریں جب رجحان کی سمت متفق ہو۔

  2. مخصوص 3 موم بتیوں کی تشکیل کی وضاحت کریں جہاں موم بتی 1 کم < موم بتی 2 کم اور موم بتی 3 کم < موم بتی 2 کم ہے۔ یہ نمونہ اپ ٹرینڈ میں طویل اندراج اور ڈاؤن ٹرینڈ میں مختصر اندراج کی نشاندہی کرتا ہے۔

  3. تیسری موم بتی جو پچھلی موم بتی کی حد کے اندر بند ہونے والی قیمت کے ساتھ اندرونی بار میں بنتی ہے ، مثالی انٹری پوائنٹ کی نشاندہی کرتی ہے۔ اندرونی بار کے ساتھ 123 پیٹرن فوری طور پر تجارتی آرڈر کی جگہ کا اشارہ کرتا ہے۔

  4. تیسری موم بتی کی اونچائی پر طویل اور تیسری موم بتی کی کم پر مختصر داخل کریں۔ موم بتی 2 کی کم (لانگ انٹری) یا موم بتی 2 کی اونچائی (مختصر انٹری) پر اسٹاپ نقصان مقرر کریں۔ 2x خطرے پر منافع حاصل کریں۔

  5. جب رجحان ، نمونہ ، اشارے اعلی امکان کی تجارت کے لئے اتفاق کرتے ہیں تو بریک آؤٹ آرڈر کریں۔ مضبوط بریک آؤٹ نقطہ نظر کے ل prof منافع میں مقفل ہونے کے لئے اسٹاپ نقصان اور منافع حاصل کریں۔

فوائد کا تجزیہ

اس حکمت عملی کے مندرجہ ذیل اہم فوائد ہیں:

  1. دوہری ای ایم اے رجحان کے خلاف تجارت سے بچنے کے لئے مجموعی رجحان کی سمت کی وضاحت کرتی ہے۔

  2. موم بتیوں کے نمونوں کو اعلی امکانات کے بریک آؤٹ فارمیشنز کے لئے اسکرین کریں.

  3. رجحان، نمونہ، اشارے میں اتفاق رائے سگنل کی کوالٹی کو یقینی بناتا ہے۔

  4. اندرونی بار سگنل کی وشوسنییتا کو بڑھا دیتا ہے اور مزید اندراج کے وقت کو محفوظ کرتا ہے۔

  5. پہلے سے مقرر سٹاپ نقصان اور منافع لے انفرادی تجارتی خطرے کا انتظام.

  6. بیک ٹسٹوں نے اعداد و شمار کے حاشیے کے لئے 65 فیصد سے زیادہ جیت کی شرح کی توثیق کی ہے۔

خلاصہ یہ کہ یہ حکمت عملی ٹرینڈ، پیٹرن اور اشارے کے جامع تجزیے کا فائدہ اٹھاتی ہے تاکہ بریک آؤٹ کا وقت درست کیا جاسکے اور اس سے مستحکم رسک ریٹرن برینڈ حاصل کیا جاسکے۔

خطرے کا تجزیہ

اہم خطرات مندرجہ ذیل سے پیدا ہوتے ہیں:

  1. غلط رجحان کی کالیں جو ہچکچاہٹ کے حالات میں غلط سگنل پیدا کرتی ہیں۔ اضافی رجحان کی پیمائش کی تصدیق کو بہتر بنا سکتی ہے۔

  2. جامد اسٹاپ نقصان / منافع حاصل کرنے میں ہر قیمت کے جھولے میں بالکل فٹ نہیں ہوتا ہے۔ موافقت پذیر زون بہتر ہوسکتے ہیں۔

  3. موم بتی پیٹرن کی شناخت وسیع پیمانے پر اصلاح کی ضرورت ہوتی ہے کہ پیرامیٹر ٹیوننگ پر منحصر ہے.

  4. بلیک سوان کے واقعات غیر متوقع ہیں جن کے تجارتی اثرات شدید ہیں۔ خطرے کے کنٹرول کے لئے پوزیشن سائزنگ کی سفارش کی جاتی ہے۔

  5. بیک ٹیسٹ کے نتائج زیادہ موزوں ہوسکتے ہیں اور براہ راست کارکردگی کو غلط طور پر پیش کرسکتے ہیں۔ پیرامیٹرز کو استحکام کی تصدیق کی ضرورت ہے۔

  6. تجارت کی زیادہ کثرت سے لین دین کی لاگت بڑھ جاتی ہے۔ جیت کی شرح اور خطرہ / انعام کا تناسب لاگت کو مناسب طریقے سے ڈھکنا چاہئے۔

پیرامیٹرز کی مناسب اصلاح ، سگنل کے اضافی طول و عرض ، اور پوزیشن سائزنگ مؤثر طریقے سے خطرات کو کم سے کم کرسکتے ہیں اور کارکردگی کے مستقل مزاجی کو بڑھا سکتے ہیں۔

اصلاح کی ہدایات

اصلاح کے اہم پہلوؤں میں شامل ہیں:

  1. زیادہ استحکام کے لئے اضافی موم بتی کی مدت کے پیرامیٹرز کی جانچ کریں.

  2. جھوٹے بریک آؤٹ سے بچنے کے لیے حجم کی تصدیق شامل کریں۔

  3. پیرامیٹر کی مضبوطی کے لئے شارپ تناسب جیسے میٹرکس کو شامل کریں.

  4. کنٹرول شدہ متحرک فوائد کے لئے منافع کی پیروی کرنے کے طریقہ کار متعارف کروائیں۔

  5. غیر یقینی صورتحال سے بچنے کے لئے VIX گھبراہٹ کی سطح کی طرف سے سگنل فلٹر.

  6. مثالی تجارت کی مدت کے لئے برقرار رکھنے کی مدت کو بہتر بنائیں.

  7. جامد سٹاپ کے علاوہ سٹاپ نقصان میکانکس کو بہتر بنائیں.

یہ اقدامات حکمت عملی کے استحکام، لچک اور منافع کو مزید بہتر بنا سکتے ہیں۔

نتیجہ

درست ٹرینڈ بریکآؤٹ ٹریڈنگ حکمت عملی اعلی امکان کے رجحان بریکآؤٹ کی گرفتاری کے لئے رجحان ، پیٹرن ، اسٹاپ نقصان / منافع کا تجزیہ کامیابی کے ساتھ جوڑتی ہے۔ واضح تجارتی سگنل ، مضبوط اشارے کی تصدیق ، اور کنٹرول شدہ خطرات کے ساتھ ، یہ ایک موثر حکمت عملی ہے جو رجحان سازی کی منڈیوں کے لئے موزوں ہے۔ مسلسل اصلاحات اور بہتری کے ساتھ ، حکمت عملی ٹرینڈ بریکآؤٹ ٹریکنگ اور پوزیشن مینجمنٹ کے لئے ایک طاقتور آلے کے طور پر وعدہ کرتی ہے ، جس سے بڑے پیمانے پر منافع حاصل کرنے کے خواہاں تاجروں کو زبردست قیمت ملتی ہے۔


/*backtest
start: 2022-11-01 00:00:00
end: 2023-10-14 05:20:00
period: 1d
basePeriod: 1h
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/

// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © julianossilva

//@version=5
strategy(title="J2S Backtest: 123-Stormer Strategy",
         shorttitle="J2S Backtest: 123-Stormer Strategy",
         overlay=true, initial_capital=1000, default_qty_value=10,
         default_qty_type = strategy.percent_of_equity, pyramiding=0)

// Initial Backtest Date Range
useStartDate = timestamp("01 Jan 2020 21:00:00")
useEndDate   = timestamp("01 Jan 2023 21:00:00")

// User Inputs
SIGNAL_CONFIG          = "BACKTEST: STORMER STRATEGY (123)"
longEntryInput         = input.bool(defval=true,         title="Long Entry",                     group=SIGNAL_CONFIG)
shortEntryInput        = input.bool(defval=true,         title="Short entry",                    group=SIGNAL_CONFIG)
thresholdForEntryInput = input.int(defval=3,             title="Threshold on clandes for entry", group=SIGNAL_CONFIG)
insideBarStrategyTitle = "Only third candle inside bar is valid"
insideBarStrategyTip   = "According to Stomer, it would be the best signal for the strategy"
insideBarStrategyInput = input.bool(defval=true,         title=insideBarStrategyTitle,           group=SIGNAL_CONFIG, tooltip=insideBarStrategyTip)
EMA_CONFIG             = "BACKTEST: EXPONENTIAL MOVING AVERAGES"
sourceInput            = input.source(defval=close,      title="Source",           inline="01",  group=EMA_CONFIG)
emaTimeframeInput      = input.timeframe("1W",           title="Timeframe",        inline="01",  group=EMA_CONFIG)
emaOffsetInput         = input.int(defval=8,             title="Offset",           inline="01",  group=EMA_CONFIG)
fastEMALengthInput     = input.int(defval=8,             title="Fast EMA Length",  inline="02",  group=EMA_CONFIG)
useFastEMAInput        = input.bool(defval=true,         title="Use Fast EMA",     inline="02",  group=EMA_CONFIG)
slowEMALengthInput     = input.int(defval=80,            title="Slow EMA Length",  inline="03",  group=EMA_CONFIG)
useSlowEMAInput        = input.bool(defval=true,         title="Use Slow EMA",     inline="03",  group=EMA_CONFIG)
PERIOD_CONFIG          = "BACKTEST: TIME PERIOD"
useDateFilterInput     = input.bool(defval=true,         title="Filter Date Range of Backtest",  group=PERIOD_CONFIG)
backtestStartDateInput = input(defval=useStartDate, title="Start Date",                     group=PERIOD_CONFIG)
backtestEndDateInput   = input(defval=useEndDate,   title="End Date",                       group=PERIOD_CONFIG)

// Colors
bbBackgroundColor  = color.rgb(33, 150, 243, 90)
candleColorDown    = color.rgb(239, 83, 80, 80)
candleColorUp      = color.rgb(38, 166, 154, 70)
insideBarColorDown = color.rgb(239, 83, 80, 40)
insideBarColorUp   = color.rgb(38, 166, 154, 20)
downTrendColor     = color.rgb(239, 83, 80, 80)
sidewaysTrendColor = color.rgb(252, 232, 131, 80)
upTrendColor       = color.rgb(38, 166, 154, 80)
buySignalColor     = color.lime
sellSignalColor    = color.orange

// Candles
isCandleUp()   => close > open
isCandleDown() => close <= open
barcolor(isCandleUp() ? candleColorUp : isCandleDown() ? candleColorDown : na)

// Exponential Moving Averages
fastEMA         = request.security(syminfo.tickerid, emaTimeframeInput, ta.ema(sourceInput, fastEMALengthInput),    barmerge.gaps_on,  barmerge.lookahead_on)
currentFastEMA  = request.security(syminfo.tickerid, emaTimeframeInput, ta.ema(sourceInput, fastEMALengthInput),    barmerge.gaps_off, barmerge.lookahead_on)
previousFastEMA = request.security(syminfo.tickerid, emaTimeframeInput, ta.ema(sourceInput[1], fastEMALengthInput), barmerge.gaps_off, barmerge.lookahead_on)
slowEMA         = request.security(syminfo.tickerid, emaTimeframeInput, ta.ema(sourceInput, slowEMALengthInput),    barmerge.gaps_on,  barmerge.lookahead_on)
currentSlowEMA  = request.security(syminfo.tickerid, emaTimeframeInput, ta.ema(sourceInput, slowEMALengthInput),    barmerge.gaps_off, barmerge.lookahead_on)
previousSlowEMA = request.security(syminfo.tickerid, emaTimeframeInput, ta.ema(sourceInput[1], slowEMALengthInput), barmerge.gaps_off, barmerge.lookahead_on)

// Trend Rules for Exponential Moving Averages
isSlowEMAUp()   => currentSlowEMA > previousSlowEMA
isSlowEMADown() => currentSlowEMA < previousSlowEMA
isFastEMAUp()   => currentFastEMA > previousFastEMA
isFastEMADown() => currentFastEMA < previousFastEMA

// Exponential Moving Average Colors
fastEMAColor = isFastEMAUp() ? upTrendColor : isFastEMADown() ? downTrendColor : sidewaysTrendColor
slowEMAColor = isSlowEMAUp() ? upTrendColor : isSlowEMADown() ? downTrendColor : sidewaysTrendColor

// Display Exponential Moving Averages
plot(useFastEMAInput ? fastEMA : na, offset=emaOffsetInput, color=fastEMAColor, title="Fast EMA", style=plot.style_line, linewidth=4)
plot(useSlowEMAInput ? slowEMA : na, offset=emaOffsetInput, color=slowEMAColor, title="Slow EMA", style=plot.style_line, linewidth=7)

// Price Trend
pricesAboveFastEMA() => low[2] > currentFastEMA and low[1] > currentFastEMA and low > currentFastEMA
pricesAboveSlowEMA() => low[2] > currentSlowEMA and low[1] > currentSlowEMA and low > currentSlowEMA
pricesBelowFastEMA() => high[2] < currentFastEMA and high[1] < currentFastEMA and high < currentFastEMA
pricesBelowSlowEMA() => high[2] < currentSlowEMA and high[1] < currentSlowEMA and high < currentSlowEMA

// Market in Bullish Trend
isBullishTrend() =>
    if useFastEMAInput and useSlowEMAInput
        pricesAboveFastEMA() and pricesAboveSlowEMA()
    else if useFastEMAInput
        pricesAboveFastEMA()
    else if useSlowEMAInput
        pricesAboveSlowEMA()
    else
        na

// Market in Bearish Trend
isBearishTrend() =>
    if useFastEMAInput and useSlowEMAInput
        pricesBelowFastEMA() and pricesBelowSlowEMA()
    else if useFastEMAInput
        pricesBelowFastEMA()
    else if useSlowEMAInput
        pricesBelowSlowEMA()
    else
        na

// Stormer Strategy (123)
isFirstCandleUp()   => high[2] > high[1] and low[2] > low[1]
isFirstCandleDown() => high[2] < high[1] and low[2] < low[1]
isThirdCandleUp()   => low > low[1]
isThirdCandleDown() => high < high[1]
isThirdCandleInsideBar() => high < high[1] and low > low[1]

// Buy Signal
isStormer123Buy() =>
    if insideBarStrategyInput
        longEntryInput and isFirstCandleUp() and isThirdCandleInsideBar() and isBullishTrend()
    else
        longEntryInput and isFirstCandleUp() and isThirdCandleUp() and isBullishTrend()

// Sell Signal
isStormer123Sell() =>
    if insideBarStrategyInput
        shortEntryInput and isFirstCandleDown() and isThirdCandleInsideBar() and isBearishTrend()
    else
        shortEntryInput and isFirstCandleDown() and isThirdCandleDown() and isBearishTrend()

// Backtest Time Period
inTradeWindow             = true
isInTradeWindow()         => inTradeWindow
isBacktestDateRangeOver() => not inTradeWindow and inTradeWindow[1]

// Backtest Price Parameters
highestPrice = ta.highest(high, 3)
lowestPrice  = ta.lowest(low,3)
priceRange   = highestPrice - lowestPrice

// Stormer Strategy (123): LONG
var myLongOrders = array.new_int(0)
longtEntryID     = "Long Entry:\n" + str.tostring(bar_index)
longExitID       = "Long Exit:\n" + str.tostring(bar_index)
stopLossInLong   = lowestPrice + 0.01
takeProfitInLong = priceRange + high

longEntryHasBeenMet = isInTradeWindow() and isBullishTrend() and isStormer123Buy()

// Scheduling LONG entry
if longEntryHasBeenMet
    array.push(myLongOrders, bar_index)
    strategy.order(longtEntryID, strategy.long, stop=high)
    strategy.exit(longExitID, longtEntryID, stop=stopLossInLong, limit=takeProfitInLong)

// In pine script, any order scheduled but not yet filled can be canceled.
// Once a order is filled, the trade is only finished with use of close or exit functions.
// As scheduled orders are not stored in the strategy.opentrades array, manual control is required.
for myOrderIndex = 0 to (array.size(myLongOrders) == 0 ? na : array.size(myLongOrders) - 1)
    myLongOrder = array.get(myLongOrders, myOrderIndex)
    if bar_index - myLongOrder == thresholdForEntryInput
        longEntryID = "Long Entry:\n" + str.tostring(myLongOrder)
        strategy.cancel(longEntryID)

// Stormer Strategy (123): SHORT
var myShortOrders = array.new_int(0)
shortEntryID      = "Short Entry:\n" + str.tostring(bar_index)
shortExitID       = "Short Exit:\n" + str.tostring(bar_index)
stopLossInShort   = highestPrice + 0.01
takeProfitInShort = low - priceRange

shortEntryHasBeenMet = isInTradeWindow() and isBearishTrend() and isStormer123Sell()

// Scheduling SHORT entry
if shortEntryHasBeenMet
    array.push(myShortOrders, bar_index)
    strategy.order(shortEntryID, strategy.short, stop=low)
    strategy.exit(shortExitID, shortEntryID, stop=stopLossInShort, limit=takeProfitInShort)

// In pine script, any order scheduled but not yet filled can be canceled.
// Once a order is filled, the trade is only finished with use of close or exit functions.
// As scheduled orders are not stored in the strategy.opentrades array, manual control is required.
for myOrderIndex = 0 to (array.size(myShortOrders) == 0 ? na : array.size(myShortOrders) - 1)
    myShortOrder = array.get(myShortOrders, myOrderIndex)
    if bar_index - myShortOrder == thresholdForEntryInput
        shortEntryID := "Short Entry:\n" + str.tostring(myShortOrder)
        strategy.cancel(shortEntryID)

// Close all positions at the end of the backtest period
if isBacktestDateRangeOver()
    strategy.cancel_all()
    strategy.close_all(comment="Date Range Exit")

// Display Signals
plotshape(series=longEntryHasBeenMet,  title="123 Buy",  style=shape.triangleup,   location=location.belowbar, color=buySignalColor,  text="123", textcolor=buySignalColor)
plotshape(series=shortEntryHasBeenMet, title="123 Sell", style=shape.triangledown, location=location.abovebar, color=sellSignalColor, text="123", textcolor=sellSignalColor)

مزید