OPEN-SOURCE SCRIPT

PTB

Von binhphan651457
Previous Highs and Lows with Fibonacci
This Pine Script indicator, "Previous Highs and Lows with Fibonacci," is designed to overlay on a trading chart and visually represent key Fibonacci levels based on historical highs and lows. It features:

Lookback Periods: The script allows you to define two lookback periods for calculating highs and lows: a short lookback period and a long lookback period. These are adjustable via input fields.

Highs and Lows Calculation: It calculates the highest and lowest values over the specified short and long periods, which are then plotted on the chart as reference lines.

Previous Highs and Lows Storage: The indicator stores the previous highs and lows for both short and long periods. These values are updated based on changes in the chart's timeframe.

Fibonacci Levels: The script calculates and plots key Fibonacci levels (0.0, 0.236, 0.382, 0.618, and 1.0) based on the highest and lowest values from the long lookback period. These Fibonacci lines are plotted as dotted lines on the chart.

Fibonacci Level Management: Old Fibonacci lines are deleted before new ones are drawn, ensuring that the chart remains uncluttered.

0.5 Fibonacci Level: The script specifically calculates and plots the 0.5 Fibonacci level, which is used to identify potential price levels of interest.

Crossing Alert: An alert condition is set to notify you when the price crosses the 0.5 Fibonacci level, which can be crucial for making trading decisions.

Plotting: In addition to the Fibonacci levels, the script plots the current highs and lows for both short and long periods for easy reference.
educational

Open-source Skript

Ganz im Sinne von TradingView hat dieser Autor sein/ihr Script als Open-Source veröffentlicht. Auf diese Weise können nun das Script auch andere Trader verstehen und prüfen. Vielen Dank an den Autor! Sie können das Script kostenlos verwenden. Die Nutzung dieses Codes in einer Veröffentlichung wird in unseren Hausregeln reguliert. Sie können es als Favoriten auswählen, um es in einem Chart zu verwenden.

Möchten Sie dieses Skript auf einem Chart verwenden?

Haftungsausschluss