OPEN-SOURCE SCRIPT
H/L Swings/pivots detector

This indicator detects and labels swing highs and swing lows using pivot logic.
It highlights market structure shifts by identifying:
- Higher Highs (HH) and Lower Highs (LH)
- Lower Lows (LL) and Higher Lows (HL)
Traders often use these levels to analyze trends, reversals, and key support/resistance zones.
The script also plots pivot markers above highs and below lows for visual clarity.
This tool is designed for educational and analytical purposes, and it does not provide financial advice or guaranteed results.
📂 Categories (choose when publishing)
Type of script → Indicator
Category → Trend Analysis (fits best for HH/LL pivots)
Optionally → Support/Resistance (if you emphasize pivots as zones)
swing high
swing low
pivot points
market structure
trend analysis
higher high
lower low
support resistance
It highlights market structure shifts by identifying:
- Higher Highs (HH) and Lower Highs (LH)
- Lower Lows (LL) and Higher Lows (HL)
Traders often use these levels to analyze trends, reversals, and key support/resistance zones.
The script also plots pivot markers above highs and below lows for visual clarity.
This tool is designed for educational and analytical purposes, and it does not provide financial advice or guaranteed results.
📂 Categories (choose when publishing)
Type of script → Indicator
Category → Trend Analysis (fits best for HH/LL pivots)
Optionally → Support/Resistance (if you emphasize pivots as zones)
swing high
swing low
pivot points
market structure
trend analysis
higher high
lower low
support resistance
สคริปต์โอเพนซอร์ซ
ด้วยเจตนารมณ์หลักของ TradingView ผู้สร้างสคริปต์นี้ได้ทำให้มันเป็นโอเพ่นซอร์ส เพื่อให้เทรดเดอร์สามารถตรวจสอบและยืนยันการทำงานของสคริปต์ได้ ขอแสดงความชื่นชมผู้เขียน! แม้ว่าคุณจะสามารถใช้งานได้ฟรี แต่อย่าลืมว่าการเผยแพร่โค้ดซ้ำนั้นจะต้องเป็นไปตามกฎระเบียบการใช้งานของเรา
คำจำกัดสิทธิ์ความรับผิดชอบ
ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ ข้อกำหนดการใช้งาน
สคริปต์โอเพนซอร์ซ
ด้วยเจตนารมณ์หลักของ TradingView ผู้สร้างสคริปต์นี้ได้ทำให้มันเป็นโอเพ่นซอร์ส เพื่อให้เทรดเดอร์สามารถตรวจสอบและยืนยันการทำงานของสคริปต์ได้ ขอแสดงความชื่นชมผู้เขียน! แม้ว่าคุณจะสามารถใช้งานได้ฟรี แต่อย่าลืมว่าการเผยแพร่โค้ดซ้ำนั้นจะต้องเป็นไปตามกฎระเบียบการใช้งานของเรา
คำจำกัดสิทธิ์ความรับผิดชอบ
ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ ข้อกำหนดการใช้งาน