This script is a simple yet effective breakout strategy designed for long-only trades. The logic is straightforward:
- **Entry Condition**: Enter long when the close price exceeds the previous high. - **Exit Condition**: Exit the position when the close price drops below the previous low.
Features: - Automatically identifies the previous high and low for every bar. - Displays these levels on the chart for easy reference.
Use this script for backtesting and exploring breakout opportunities in various markets. Let us know your thoughts and how it works for you in the comments!
Disclaimer: This script is for educational purposes only and is not financial advice. Past performance does not guarantee future results. - Perfect for trend-following traders looking for a mechanical, rule-based approach.