OPEN-SOURCE SCRIPT
تم تحديثه

Monthly & Weekly Macro Keys

5 486
Monthly & Weekly Macro Keys plots completed monthly and weekly High, Low, Open, and Close levels with composite IPDA-style premium/discount context.

Monthly macros default to the last three completed months. Each level is labeled by calendar month (for example, June 2026 Monthly High). Weekly macro key levels default to the prior completed week High and Low, with optional Open and Close. Lines begin on the day the print occurred and extend to a configurable right-side buffer next to the labels.

A composite range is built from the selected months or weeks. The indicator can draw the IPDA gradient through that range: 12.5%, 25%, 37.5%, equilibrium (50%), 62.5%, 75%, and 87.5%. High and Low of the composite are not duplicated on the gradient because they are already shown as the monthly or weekly macros.

An on-chart table reports Premium or Discount relative to equilibrium, percent location within the range, whether price is inside the 25–75% zone, and the key price levels for both the monthly and weekly composites.

Style controls include color, width, and line style (Solid, Dotted, Dashed) for monthly and weekly High, Low, and Open/Close, as well as for gradient quadrant and octant levels. Table position supports all nine chart anchors. Lookback counts are adjustable (up to six months and eight weeks).
ملاحظات الأخبار
1. Fixed bug lining up on Daily chart after Friday close.

***Will try to find time to fix the lines so they align on the precise point of all timeframes.
ملاحظات الأخبار
1. Fixed alignment issue on all chart time frames.
ملاحظات الأخبار
1. Fixed current month's close from appearing prematurely.
ملاحظات الأخبار
1. Capped history buffer upfront due to reports on TV's Essential plan limitations.

إخلاء المسؤولية

لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.