হেকিন আশি ROC পারসেন্টাইল ট্রেডিং কৌশল

লেখক:চাওঝাং, তারিখ: ২০২৩-১০-২৩ 15:41:40
ট্যাগঃ

img

সারসংক্ষেপ

এই কৌশলটিকে Heikin Ashi ROC Percentile Trading Strategy বলা হয়। এর লক্ষ্য হেকিন আশি ROC এবং এর শতাংশের উপর ভিত্তি করে একটি সহজেই ব্যবহারযোগ্য ট্রেডিং ফ্রেমওয়ার্ক সরবরাহ করা।

কৌশলগত যুক্তি

কৌশলটি গত rocLength সময়কালে হেইকিন আশির ROC বন্ধের মূল্য গণনা করে। এটি তারপরে গত 50 সময়ের মধ্যে ROC এর সর্বোচ্চ rocHigh এবং সর্বনিম্ন rocLow মান গণনা করে। উপরের রেল উপরের কিললাইন এবং নিম্ন রেল নিম্ন কিললাইন রকহাই এবং রকল্লোর নির্দিষ্ট শতাংশের উপর ভিত্তি করে উত্পন্ন হয়। যখন ROC নিম্ন কিললাইনের উপরে অতিক্রম করে, তখন একটি দীর্ঘ অবস্থান খোলা হয়। যখন ROC উপরের কিললাইনের নীচে অতিক্রম করে, তখন দীর্ঘ অবস্থান বন্ধ হয়। বিপরীতভাবে, যখন ROC উপরের কিললাইনের নীচে অতিক্রম করে, তখন একটি শর্ট অবস্থান খোলা হয়। যখন ROC নিম্ন কিললাইন অতিক্রম করে, তখন শর্ট অবস্থান বন্ধ হয়।

সুবিধা বিশ্লেষণ

এই কৌশলটির সবচেয়ে বড় সুবিধা হল ROC সূচকের শক্তিশালী প্রবণতা ট্র্যাকিং ক্ষমতা, হেইকিন আশির মূল্য তথ্য মসৃণ করার বৈশিষ্ট্যটির সাথে মিলিয়ে ব্যবহার করা। এটি কৌশলটিকে প্রবণতা পরিবর্তনগুলি কার্যকরভাবে সনাক্ত করতে এবং সময়মত ব্যবসায় প্রবেশের অনুমতি দেয়। সহজ চলমান গড়ের তুলনায়, ROC মূল্য পরিবর্তনের প্রতি আরও সংবেদনশীলভাবে প্রতিক্রিয়া জানায়। অতিরিক্তভাবে, শতাংশ থেকে উত্পন্ন উপরের এবং নীচের রেলগুলি কার্যকরভাবে সংহতকরণ ফিল্টার করতে পারে এবং জাল ব্রেকআউট থেকে অপ্রয়োজনীয় ব্যবসায় এড়াতে পারে। সামগ্রিকভাবে, এই কৌশলটি প্রধান প্রবণতাগুলিতে ভাল ঝুঁকি-পুরষ্কার অনুপাত অর্জনের জন্য প্রবণতা অনুসরণ এবং দোলন ফিল্টারিং উভয়ই একত্রিত করে।

ঝুঁকি বিশ্লেষণ

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

অপ্টিমাইজেশান নির্দেশাবলী

কৌশলটি নিম্নলিখিত উপায়ে অপ্টিমাইজ করা যেতে পারেঃ 1) আরএসআইয়ের মতো অন্যান্য সূচকগুলির সাথে ফিল্টার যুক্ত করুন; 2) মেশিন লার্নিংয়ের সাথে গতিশীলভাবে পরামিতিগুলি অনুকূল করুন; 3) স্বয়ংক্রিয় ঝুঁকি পরিচালনার জন্য স্টপ লস এবং লাভ নিন সেট করুন; 4) ঝুঁকিগুলি ভারসাম্যপূর্ণ করার জন্য নন-ট্রেন্ড কৌশলগুলির সাথে একত্রিত করুন।

সংক্ষিপ্তসার

সংক্ষেপে, এই কৌশলটি প্রবণতা সনাক্তকরণ এবং অনুসরণ করার জন্য হেইকিন আশির সাথে মিলিত ROC সূচকের শক্তিশালী প্রবণতা ট্র্যাকিং ক্ষমতা ব্যবহার করে। ROC শতাংশ থেকে উত্পন্ন উপরের এবং নীচের রেলগুলি কার্যকর ক্ষতি ফিল্টারিংয়ের অনুমতি দেয়। এটি ভাল প্রবণতা ট্র্যাকিং কর্মক্ষমতা অর্জন করে। এর সুবিধাগুলি রেলগুলির সাথে একীকরণ ফিল্টার করার সময় প্রবণতা পরিবর্তন এবং প্রধান প্রবণতা অনুসরণে রয়েছে। তবে, অনুপযুক্ত পরামিতি সেটিংগুলি কর্মক্ষমতাকে প্রভাবিত করতে পারে এবং প্রবণতা বিপরীত ঝুঁকিগুলি রয়ে যায়। আরও প্যারামিটার নির্বাচন এবং স্টপ সেটিং আরও ধারাবাহিক ফলাফল পেতে সহায়তা করতে পারে।


/*backtest
start: 2023-09-22 00:00:00
end: 2023-10-22 00:00:00
period: 1h
basePeriod: 15m
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/
// © jensenvilhelm

//@version=5
strategy("Heikin Ashi ROC Percentile Strategy", shorttitle="ROC ON" , overlay=false)

// User Inputs
zerohLine = input(0, title="Midline")  // Zero line, baseline for ROC (customer can modify this to adjust midline)
rocLength = input(100, title="roc Length")  // Lookback period for SMA and ROC (customer can modify this to adjust lookback period)

stopLossLevel = input(2, title="Stop Loss (%)")  // Level at which the strategy stops the loss (customer can modify this to adjust stop loss level)
startDate = timestamp("2015 03 03")  // Start date for the strategy (customer can modify this to adjust start date)

// Heikin Ashi values
var float haClose = na  // Define Heikin Ashi close price
var float haOpen = na  // Define Heikin Ashi open price
haClose := ohlc4  // Calculate Heikin Ashi close price as average of OHLC4 (no customer modification needed here)
haOpen := na(haOpen[1]) ? (open + close) / 2 : (haOpen[1] + haClose[1]) / 2  // Calculate Heikin Ashi open price (no customer modification needed here)

// ROC Calculation
roc = ta.roc(ta.sma(haClose, rocLength), rocLength)  // Calculate Rate of Change (ROC) (customer can modify rocLength in the inputs)
rocHigh = ta.highest(roc, 50)  // Get the highest ROC of the last 50 periods (customer can modify this to adjust lookback period)
rocLow = ta.lowest(roc, 50)  // Get the lowest ROC of the last 50 periods (customer can modify this to adjust lookback period)
upperKillLine = ta.percentile_linear_interpolation(rocHigh, 10, 75)  // Calculate upper kill line (customer can modify parameters to adjust this line)
lowerKillLine = ta.percentile_linear_interpolation(rocLow, 10, 25)  // Calculate lower kill line (customer can modify parameters to adjust this line)

// Trade conditions
enterLong = ta.crossover(roc, lowerKillLine)  // Define when to enter long positions (customer can modify conditions to adjust entry points)
exitLong = ta.crossunder(roc, upperKillLine)  // Define when to exit long positions (customer can modify conditions to adjust exit points)
enterShort = ta.crossunder(roc, upperKillLine)  // Define when to enter short positions (customer can modify conditions to adjust entry points)
exitShort = ta.crossover(roc, lowerKillLine )  // Define when to exit short positions (customer can modify conditions to adjust exit points)

// Strategy execution
if(time >= startDate)  // Start strategy from specified start date
    if (enterLong)
        strategy.entry("Long", strategy.long)  // Execute long trades
    if (exitLong)
        strategy.close("Long")  // Close long trades
    if (enterShort)
        strategy.entry("Short", strategy.short)  // Execute short trades
    if (exitShort)
        strategy.close("Short")  // Close short trades

// Plotting
plot(zerohLine,title="Zeroline")  // Plot zero line
plot(roc, "RSI", color=color.rgb(248, 248, 248))  // Plot ROC
plot(rocHigh, "Roc High", color = color.rgb(175, 78, 76))  // Plot highest ROC
plot(rocLow, "Roc Low", color = color.rgb(175, 78, 76))  // Plot lowest ROC
plot(upperKillLine, "Upper Kill Line", color = color.aqua)  // Plot upper kill line
plot(lowerKillLine, "Lower Kill Line", color = color.aqua)  // Plot lower kill line


আরো