Release Notes for Pivot-based Swing Highs and Lows Indicator with HH, HL, LH, LL and Labels Version 1.0.0 Release Date: 29th Sept 2024
Overview: This Pine Script version 5 indicator is designed to identify and display Swing Highs and Swing Lows based on pivot points. The indicator visually marks Higher Highs (HH), Lower Highs (LH), Higher Lows (HL), and Lower Lows (LL) on the chart. The release introduces an improved visual representation with dotted lines and colored labels for easy identification of market structure, using plotshape() and line.new().
Key Features: 1. Pivot-Based Swing Identification: The indicator uses ta.pivothigh() and ta.pivotlow() to detect significant pivot points on the chart. The length of the pivot can be adjusted through the pivot_length parameter, allowing users to customize the sensitivity of swing identification.
2. Swing Highs and Lows with Labels: Higher High (HH) and Lower High (LH) points are marked with green downward triangles. Higher Low (HL) and Lower Low (LL) points are marked with red upward triangles. The plotshape() function is used to provide clear visual markers, making it easy to spot the changes in market structure.
3. Dotted Line Visuals: Green Dotted Lines: Connect Higher Highs (HH) and Higher Lows (HL) to their corresponding previous swings. Red Dotted Lines: Connect Lower Highs (LH) and Lower Lows (LL) to their corresponding previous swings. The use of color-coded dotted lines ensures better visual understanding of the trend continuation or reversal patterns.
4. Customizable Input: The user can adjust the pivot_length parameter to fine-tune the detection of pivot highs and lows according to different timeframes or trading strategies.
Usage: Higher High (HH): Green downward triangle, indicating a new high compared to the previous pivot high. Lower High (LH): Green downward triangle, indicating a lower high compared to the previous pivot high. Higher Low (HL): Red upward triangle, indicating a higher low compared to the previous pivot low. Lower Low (LL): Red upward triangle, indicating a new lower low compared to the previous pivot low. Dotted Lines: Connect previous swing points, helping users visualize the trend and potential market structure changes.
Improvements: Label Substitution: In place of label.new() (which might cause issues in some environments), the indicator now uses plotshape() to provide a reliable and visually effective solution for marking swings. Streamlined Performance: The logic for determining higher highs, lower highs, higher lows, and lower lows has been optimized for smooth performance across multiple timeframes.
Known Limitations: No Direct Text Labels: Due to the constraints of plotshape(), text labels like "HH", "LH", "HL", and "LL" are not directly displayed. Instead, color-coded shapes are used for easy identification.
How to Use: Apply the script to your chart via the TradingView Pine Editor. Customize the pivot_length to suit your trading style or the timeframe you are analyzing. Monitor the chart for marked Higher Highs, Lower Highs, Higher Lows, and Lower Lows for potential trend continuation or reversal opportunities. Use the dotted lines to trace the evolution of market structure.
Please share your comments, thoughts. Also please follow me for more scripts in future. Mean time Happy Trading :)
قام مؤلف هذا النص البرمجي بنشره وجعله مفتوح المصدر، بحيث يمكن للمتداولين فهمه والتحقق منه، وهو الأمر الذي يدخل ضمن قيم TradingView. تحياتنا للمؤلف! يمكنك استخدامه مجانًا، ولكن إعادة استخدام هذا الرمز في المنشور يخضع لقواعدقوانين الموقع. يمكنك جعله مفضلاً لاستخدامه على الرسم البياني.
هل تريد استخدام هذا النص البرمجي على الرسم البياني؟
لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.