OPEN-SOURCE SCRIPT
Clean Zone + SL/TP (Latest Only)

📌 Description
Clean Zone + SL/TP (Latest Only) is an indicator designed to highlight the most recent supply or demand zone based on pivot highs/lows, and automatically plot entry, stop loss, and multiple take profit levels.
🔹 Automatic Direction Detection
The script can auto-detect trade direction (Long/Short) using pivot logic, or you can override manually.
🔹 Zone Drawing
Only the latest valid supply (red) or demand (green) zone is displayed.
Zones are extended to the right for a customizable number of bars.
🔹 Entry / SL / TP Levels
Entry, Stop Loss, and TP1/TP2/TP3 levels are plotted automatically.
Targets can be calculated either by zone size or by ATR-based multiples.
Risk/Reward ratios are fully adjustable.
🔹 Customizable Display
Toggle visibility for zones (box), entry/SL/TP lines, and price labels.
Labels show only on the latest bar for a clean chart look.
🎯 Use Case
This tool helps traders quickly identify the cleanest and most recent supply/demand setup and manage trades with predefined risk/reward targets. It’s especially useful for price action traders and those who prefer simple, uncluttered charts.
Clean Zone + SL/TP (Latest Only) is an indicator designed to highlight the most recent supply or demand zone based on pivot highs/lows, and automatically plot entry, stop loss, and multiple take profit levels.
🔹 Automatic Direction Detection
The script can auto-detect trade direction (Long/Short) using pivot logic, or you can override manually.
🔹 Zone Drawing
Only the latest valid supply (red) or demand (green) zone is displayed.
Zones are extended to the right for a customizable number of bars.
🔹 Entry / SL / TP Levels
Entry, Stop Loss, and TP1/TP2/TP3 levels are plotted automatically.
Targets can be calculated either by zone size or by ATR-based multiples.
Risk/Reward ratios are fully adjustable.
🔹 Customizable Display
Toggle visibility for zones (box), entry/SL/TP lines, and price labels.
Labels show only on the latest bar for a clean chart look.
🎯 Use Case
This tool helps traders quickly identify the cleanest and most recent supply/demand setup and manage trades with predefined risk/reward targets. It’s especially useful for price action traders and those who prefer simple, uncluttered charts.
สคริปต์โอเพนซอร์ซ
ด้วยเจตนารมณ์หลักของ TradingView ผู้สร้างสคริปต์นี้ได้ทำให้มันเป็นโอเพ่นซอร์ส เพื่อให้เทรดเดอร์สามารถตรวจสอบและยืนยันการทำงานของสคริปต์ได้ ขอแสดงความชื่นชมผู้เขียน! แม้ว่าคุณจะสามารถใช้งานได้ฟรี แต่อย่าลืมว่าการเผยแพร่โค้ดซ้ำนั้นจะต้องเป็นไปตามกฎระเบียบการใช้งานของเรา
คำจำกัดสิทธิ์ความรับผิดชอบ
ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ ข้อกำหนดการใช้งาน
สคริปต์โอเพนซอร์ซ
ด้วยเจตนารมณ์หลักของ TradingView ผู้สร้างสคริปต์นี้ได้ทำให้มันเป็นโอเพ่นซอร์ส เพื่อให้เทรดเดอร์สามารถตรวจสอบและยืนยันการทำงานของสคริปต์ได้ ขอแสดงความชื่นชมผู้เขียน! แม้ว่าคุณจะสามารถใช้งานได้ฟรี แต่อย่าลืมว่าการเผยแพร่โค้ดซ้ำนั้นจะต้องเป็นไปตามกฎระเบียบการใช้งานของเรา
คำจำกัดสิทธิ์ความรับผิดชอบ
ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ ข้อกำหนดการใช้งาน