New obv-vwap

// @version=5 indicator("CCRS مع مؤشر OBV و VWAP", overlay=true) // تعيين المدى الزمني إلى أسبوعي timeframe = "1W" // استدعاء بيانات السهم بالمدى الزمني المحدد [open_tf, high_tf, low_tf, close_tf, volume_tf] = request.security(syminfo.tickerid, timeframe, [open, high, low, close, volume]) // حساب مؤشر OBV (On-Balance Volume) obv_calc = ta.obv(close_tf, volume_tf) // حساب مؤشر VWAP (Volume Weighted Average Price) vwap_calc = ta.vwap(close_tf) // رسم الشارت الرئيسي plot(close_tf, title="سعر سهم CCRS", color=color.blue, linewidth=2) // عرض المؤشرات في نوافذ منفصلة // مؤشر OBV obv_panel = panel.new("OBV") plot(obv_calc, title="مؤشر OBV", color=color.purple, linewidth=2, panel=obv_panel) // مؤشر VWAP vwap_panel = panel.new("VWAP") plot(vwap_calc, title="مؤشر VWAP", color=color.orange, linewidth=2, panel=vwap_panel) // إضافة وصف للمؤشر var table info = table.new(position.top_right, 3, 3, bgcolor=color.new(color.blue, 90), frame_color=color.new(color.blue, 80), frame_width=1) table.cell(info, 0, 0, "CCRS", bgcolor=color.new(color.blue, 90), text_color=color.white) table.cell(info, 0, 1, "OBV", bgcolor=color.new(color.purple, 90), text_color=color.white) table.cell(info, 0, 2, "VWAP", bgcolor=color.new(color.orange, 90), text_color=color.white) // طريقة استخدام المؤشر var table usage = table.new(position.bottom_right, 1, 1, bgcolor=color.new(color.gray, 90)) table.cell(usage, 0, 0, "المدى الزمني: أسبوعي", text_color=color.white)

إرسال تعليق

أحدث أقدم

نموذج الاتصال