গতিশীল তরলতা বাজার কাঠামোকে অভিযোজিত ট্রেডিং কৌশলগুলিকে চালিত করে

LZ MSS SL TP ISL
সৃষ্টির তারিখ: 2025-03-28 17:13:02 অবশেষে সংশোধন করুন: 2025-03-28 17:13:02
অনুলিপি: 2 ক্লিকের সংখ্যা: 350
2
ফোকাস
319
অনুসারী

গতিশীল তরলতা বাজার কাঠামোকে অভিযোজিত ট্রেডিং কৌশলগুলিকে চালিত করে গতিশীল তরলতা বাজার কাঠামোকে অভিযোজিত ট্রেডিং কৌশলগুলিকে চালিত করে

ওভারভিউ

এটি একটি উদ্ভাবনী ট্রেডিং কৌশল যা তরল অঞ্চল বিশ্লেষণ এবং অভ্যন্তরীণ বাজারের কাঠামোগত গতিশীলতার সাথে মিলিত হয়, যা উচ্চ সম্ভাব্যতা প্রবেশের পয়েন্টগুলি সনাক্ত করার লক্ষ্যে তৈরি করা হয়েছে। এই কৌশলটি মূল বাজারের স্তরের সাথে দামের মিথস্ক্রিয়া অনুসরণ করে এবং অভ্যন্তরীণ বাজারের রূপান্তর ব্যবহার করে ট্রেডিংয়ের সূত্রপাত করে, যা ব্যবসায়ীদের বাজারে প্রবেশের একটি নমনীয় এবং সুনির্দিষ্ট পদ্ধতি সরবরাহ করে।

কৌশল নীতি

কৌশলটির কেন্দ্রীয় যুক্তি দুটি মূল উপাদানগুলির উপর ভিত্তি করে তৈরি করা হয়েছেঃ তরল অঞ্চল সনাক্তকরণ এবং অভ্যন্তরীণ বাজার রূপান্তর। তরল অঞ্চলগুলি গতিশীলভাবে স্থানীয় উচ্চতা এবং নিম্নের বিশ্লেষণের মাধ্যমে নির্ধারিত হয়, এবং অভ্যন্তরীণ বাজার রূপান্তরগুলি বাজার দিকের পরিবর্তনের বিচার করার জন্য পূর্ববর্তী বুলিশ বা বিয়ারিশ স্তরগুলি ভেঙে দেয়।

এই কৌশলটির মূল বৈশিষ্ট্যগুলো হলঃ

  1. অভ্যন্তরীণ বাজার রূপান্তর লজিকঃ ঐতিহ্যবাহী ফ্রেমওয়ার্কের উপর নির্ভর করে না, বরং মূল্যের উপর ভিত্তি করে
  2. লিকুইডিটি জোন ট্র্যাকিংঃ ডায়নামিকভাবে মূল লিকুইডিটি জোনগুলি চিহ্নিত করুন যাতে দুর্বল বাজার পরিস্থিতিতে লেনদেন প্রতিরোধ করা যায়
  3. মডেলের নমনীয়তাঃ “Both”, “Bullish Only” এবং “Bearish Only” তিনটি ট্রেডিং মোড উপলব্ধ
  4. ঝুঁকি ব্যবস্থাপনাঃ কাস্টমাইজড স্টপ লস এবং স্টপস্টপ স্তর
  5. টাইমস্পেস কন্ট্রোলঃ ট্রেডিংয়ের সময়কালের উপর সুনির্দিষ্ট নিয়ন্ত্রণ

কৌশলগত সুবিধা

  1. ডায়নামিক অ্যাডাপ্টিভঃ কৌশলগুলি দ্রুত বাজার কাঠামোর পরিবর্তনে সাড়া দেয়
  2. সুনির্দিষ্ট প্রবেশাধিকারঃ লিকুইডিটি অঞ্চল এবং অভ্যন্তরীণ বাজার রূপান্তরকে একত্রিত করে সুনির্দিষ্ট প্রবেশাধিকার বাড়ানো
  3. ঝুঁকি নিয়ন্ত্রণযোগ্যঃ বিল্ট-ইন স্টপ অ্যান্ড স্টপ মেকানিজম
  4. নমনীয়তাঃ বিভিন্ন বাজারের অবস্থার উপর ভিত্তি করে ট্রেডিং মোড নির্বাচন করা যায়
  5. মাল্টি-ডাইমেনশনাল অ্যানালিসিসঃ দামের আচরণ, তরলতা এবং বাজারের কাঠামো বিবেচনা করে

কৌশলগত ঝুঁকি

  1. বাজারের তীব্র অস্থিরতার ফলে স্টপ লস ট্রিগার হতে পারে
  2. বাজারে ঘন ঘন সিগন্যালের কারণে লেনদেনের খরচ বাড়তে পারে
  3. অনুপযুক্ত প্যারামিটার সেটিংস কৌশল কর্মক্ষমতা প্রভাবিত করতে পারে
  4. রিটার্নিং ফলাফলগুলি বাস্তব ডিস্কের চেয়ে আলাদা হতে পারে

কৌশল অপ্টিমাইজেশনের দিকনির্দেশনা

  1. মেশিন লার্নিং অ্যালগরিদম প্রবর্তন করা হয়েছে প্যারামিটার স্ব-অনুকূলিতকরণের জন্য
  2. ট্রেডিং ভলিউম, অস্থিরতা সূচক ইত্যাদির মতো আরও ফিল্টার যুক্ত করুন
  3. মাল্টি টাইম ফ্রেম ভ্যালিডেশন ম্যানেজমেন্ট
  4. স্টপ লস এবং স্টপ-অফ অ্যালগরিদমগুলিকে অপ্টিমাইজ করুন, বাজারের অস্থিরতার গতিশীলতা বিবেচনা করে

সারসংক্ষেপ

এটি একটি উদ্ভাবনী ট্রেডিং কৌশল যা তরলতা বিশ্লেষণ এবং বাজার কাঠামোর গতিশীলতার সাথে একত্রিত হয়। এটি নমনীয় অভ্যন্তরীণ বাজার রূপান্তর লজিক এবং সঠিক তরলতা অঞ্চল ট্র্যাকিংয়ের মাধ্যমে ব্যবসায়ীদের জন্য একটি শক্তিশালী ট্রেডিং সরঞ্জাম সরবরাহ করে। কৌশলটির মূল চাবিকাঠি হ’ল এটির অভিযোজনযোগ্যতা এবং বহুমুখী বিশ্লেষণের ক্ষমতা, যা বিভিন্ন বাজারের অবস্থার অধীনে উচ্চ কার্যকারিতা বজায় রাখতে সক্ষম।

কৌশল সোর্স কোড
/*backtest
start: 2024-03-28 00:00:00
end: 2025-03-27 00:00:00
period: 1d
basePeriod: 1d
exchanges: [{"eid":"Futures_Binance","currency":"ETH_USDT"}]
*/

//@version=6
strategy("Liquidity + Internal Market Shift Strategy", overlay=true)

// ======== Mode Selection ========
mode = input.string("Both", title="Mode", options=["Both", "Bullish Only", "Bearish Only"])

// ======== Stop-Loss and Take-Profit Input (in pips) ========
enableTakeProfit = input.bool(true, title="Enable Custom Take Profit")  // Option to enable/disable take profit
stopLossPips = input.int(10, title="Stop Loss (in pips)", minval=1)  // Stop loss in pips
takeProfitPips = input.int(20, title="Take Profit (in pips)", minval=1)  // Take profit in pips

// ======== Internal Shift Logic ========

// Fixed number of consecutive candles to track (set to 1)
consecutiveBullishCount = 1
consecutiveBearishCount = 1

// Function to check for bullish and bearish candles
isBullish = close > open
isBearish = close < open

// Variables to track consecutive candles and mark lowest/highest
var int bullishCount = 0
var int bearishCount = 0
var float lowestBullishPrice = na
var float highestBearishPrice = na
var float previousBullishPrice = na // For the previous bullish lowest price
var float previousBearishPrice = na // For the previous bearish highest price

// Variables to track last internal shift type (1 = Bullish, -1 = Bearish, 0 = None)
var int lastInternalShift = 0

// Counting consecutive bullish and bearish candles
if isBullish
    bullishCount := bullishCount + 1
    bearishCount := 0
    if bullishCount == 1 or low < lowestBullishPrice
        lowestBullishPrice := low
else if isBearish
    bearishCount := bearishCount + 1
    bullishCount := 0
    if bearishCount == 1 or high > highestBearishPrice
        highestBearishPrice := high
else
    bullishCount := 0
    bearishCount := 0
    lowestBullishPrice := na
    highestBearishPrice := na

// Internal shift conditions
internalShiftBearish = close < previousBullishPrice and close < lowestBullishPrice
internalShiftBullish = close > previousBearishPrice and close > highestBearishPrice

// Condition to alternate internal shifts
allowInternalShiftBearish = internalShiftBearish and lastInternalShift != -1
allowInternalShiftBullish = internalShiftBullish and lastInternalShift != 1

// Tracking shifts
if bullishCount >= consecutiveBullishCount
    previousBullishPrice := lowestBullishPrice

if bearishCount >= consecutiveBearishCount
    previousBearishPrice := highestBearishPrice

// ======== Liquidity Seal-Off Points Logic ========
upperLiquidityLookback = input.int(10, title="Lookback Period for Upper Liquidity Line")
lowerLiquidityLookback = input.int(10, title="Lookback Period for Lower Liquidity Line")

isLocalHigh = high == ta.highest(high, upperLiquidityLookback)
isLocalLow = low == ta.lowest(low, lowerLiquidityLookback)

var bool touchedLowerLiquidityLine = false
var bool touchedUpperLiquidityLine = false

if (low <= ta.lowest(low, lowerLiquidityLookback))
    touchedLowerLiquidityLine := true

if (high >= ta.highest(high, upperLiquidityLookback))
    touchedUpperLiquidityLine := true

var bool lockedBullish = false
var bool lockedBearish = false
var int barSinceLiquidityTouch = na

// ======== Combined Signals ========
bullishSignal = allowInternalShiftBullish and touchedLowerLiquidityLine and not lockedBullish
bearishSignal = allowInternalShiftBearish and touchedUpperLiquidityLine and not lockedBearish

if bullishSignal
    lockedBullish := true
    touchedLowerLiquidityLine := false
    barSinceLiquidityTouch := 0

if bearishSignal
    lockedBearish := true
    touchedUpperLiquidityLine := false
    barSinceLiquidityTouch := 0

if not na(barSinceLiquidityTouch)
    barSinceLiquidityTouch := barSinceLiquidityTouch + 1

if barSinceLiquidityTouch >= 3
    lockedBullish := false
    lockedBearish := false

if touchedLowerLiquidityLine
    lockedBullish := false

if touchedUpperLiquidityLine
    lockedBearish := false

// ======== Plot Combined Signals ========
plotshape(bullishSignal, style=shape.triangleup, location=location.belowbar, color=color.green, size=size.tiny, title="Bullish Signal")
plotshape(bearishSignal, style=shape.triangledown, location=location.abovebar, color=color.red, size=size.tiny, title="Bearish Signal")

plot(isLocalHigh ? high : na, color=color.red, linewidth=2, style=plot.style_stepline, title="Local High Line")
plot(isLocalLow ? low : na, color=color.green, linewidth=2, style=plot.style_stepline, title="Local Low Line")

// ======== Track Entry and Opposing Signals ========
var float entryPrice = na
var int entryTime = na
var string positionSide = ""

// ======== Strategy Execution (Mode Logic) ========
if (mode == "Both")
    // Short Entry Logic (Bearish Signal)
    if (bearishSignal and na(entryPrice))
        strategy.entry("Short", strategy.short)
        entryPrice := close
        entryTime := time
        positionSide := "short"
    
    // Long Entry Logic (Bullish Signal)
    if (bullishSignal and na(entryPrice))
        strategy.entry("Long", strategy.long)
        entryPrice := close
        entryTime := time
        positionSide := "long"

    // Exit Logic: Close on Opposing Signal (after the current signal is triggered)
    if (positionSide == "short" and bullishSignal )
        strategy.close("Short")
        entryPrice := na
        positionSide := ""
    
    if (positionSide == "long" and bearishSignal)
        strategy.close("Long")
        entryPrice := na
        positionSide := ""
    
    // Stop-Loss and Take-Profit Logic (in pips)
    stopLossPriceLong = entryPrice - stopLossPips * syminfo.mintick
    takeProfitPriceLong = entryPrice + takeProfitPips * syminfo.mintick
    stopLossPriceShort = entryPrice + stopLossPips * syminfo.mintick
    takeProfitPriceShort = entryPrice - takeProfitPips * syminfo.mintick
    
    // Long Stop-Loss and Take-Profit Conditions
    if (positionSide == "long" and close <= stopLossPriceLong)
        strategy.close("Long", comment="Stop Loss Triggered")
        entryPrice := na
        positionSide := ""

    if (positionSide == "long" and enableTakeProfit and close >= takeProfitPriceLong)
        strategy.close("Long", comment="Take Profit Triggered")
        entryPrice := na
        positionSide := ""

    // Short Stop-Loss and Take-Profit Conditions
    if (positionSide == "short" and close >= stopLossPriceShort)
        strategy.close("Short", comment="Stop Loss Triggered")
        entryPrice := na
        positionSide := ""

    if (positionSide == "short" and enableTakeProfit and close <= takeProfitPriceShort)
        strategy.close("Short", comment="Take Profit Triggered")
        entryPrice := na
        positionSide := ""

if (mode == "Bullish Only")
    if (bullishSignal and na(entryPrice))
        strategy.entry("Long", strategy.long)
        entryPrice := close
        entryTime := time
        positionSide := "long"
    
    if (positionSide == "long" and bearishSignal)
        strategy.close("Long")
        entryPrice := na
        positionSide := ""

    // Stop-Loss and Take-Profit Logic (in pips)
    stopLossPriceLong = entryPrice - stopLossPips * syminfo.mintick
    takeProfitPriceLong = entryPrice + takeProfitPips * syminfo.mintick
    
    if (positionSide == "long" and close <= stopLossPriceLong)
        strategy.close("Long", comment="Stop Loss Triggered")
        entryPrice := na
        positionSide := ""

    if (positionSide == "long" and enableTakeProfit and close >= takeProfitPriceLong)
        strategy.close("Long", comment="Take Profit Triggered")
        entryPrice := na
        positionSide := ""

if (mode == "Bearish Only")
    if (bearishSignal and na(entryPrice))
        strategy.entry("Short", strategy.short)
        entryPrice := close
        entryTime := time
        positionSide := "short"
    
    if (positionSide == "short" and bullishSignal)
        strategy.close("Short")
        entryPrice := na
        positionSide := ""

    // Stop-Loss and Take-Profit Logic (in pips)
    stopLossPriceShort = entryPrice + stopLossPips * syminfo.mintick
    takeProfitPriceShort = entryPrice - takeProfitPips * syminfo.mintick
    
    if (positionSide == "short" and close >= stopLossPriceShort)
        strategy.close("Short", comment="Stop Loss Triggered")
        entryPrice := na
        positionSide := ""

    if (positionSide == "short" and enableTakeProfit and close <= takeProfitPriceShort)
        strategy.close("Short", comment="Take Profit Triggered")
        entryPrice := na
        positionSide := ""