DhanVibes

CS Patterns

DhanVibes Diupdate   
Overview
The CS Patterns indicator is designed to identify and highlight various candlestick patterns on a trading chart. Candlestick patterns are a crucial tool for traders as they help in predicting market movements and potential reversals. This indicator includes single, double, and triple candlestick patterns without revealing the source code, making it an ideal tool for traders who want to utilize advanced pattern recognition while keeping the script proprietary.

Candlestick Patterns Included
Single Candlestick Patterns

Bullish Hammer:
  • Found at the bottom of a downtrend.
  • Features a small body, long lower shadow, and little to no upper shadow.
  • Indicates potential reversal to an uptrend.

Bearish Hanging Man:
  • Found at the top of an uptrend.
  • Similar structure to the Bullish Hammer but indicates a potential reversal to a downtrend.

Bullish Inverted Hammer:
  • Found at the bottom of a downtrend.
  • Features a small body, long upper shadow, and little to no lower shadow.
  • Suggests a potential reversal to an uptrend.

Bearish Shooting Star:
  • Found at the top of an uptrend.
  • Indicates a potential reversal to a downtrend.

Dragonfly Doji:
  • Small or non-existent upper shadow and long lower shadow.
  • Indicates a potential reversal when found at the bottom of a trend.

Gravestone Doji:
  • Long upper shadow and small or non-existent lower shadow.
  • Indicates a potential reversal when found at the top of a trend.

Standard Doji:
  • Very small body, indicates indecision in the market.
  • Can signal reversals when found at the tops or bottoms of trends.

Long-Legged Doji:
  • Long upper and lower shadows with a small body.
  • Indicates a potential market reversal.


Double Candlestick Patterns

Bullish Engulfing:
  • A smaller bearish candle followed by a larger bullish candle that engulfs it.
  • Indicates a potential reversal to an uptrend.

Bearish Engulfing:
  • A smaller bullish candle followed by a larger bearish candle that engulfs it.
  • Indicates a potential reversal to a downtrend.

Bullish Harami:
  • A large bearish candle followed by a smaller bullish candle within its range.
  • Indicates a potential reversal to an uptrend.

Bearish Harami:
  • A large bullish candle followed by a smaller bearish candle within its range.
  • Indicates a potential reversal to a downtrend.

Bullish Piercing Line:
  • A bearish candle followed by a bullish candle that closes above the midpoint of the previous candle.
  • Indicates a potential reversal to an uptrend.

Bearish Dark Cloud Cover:
  • A bullish candle followed by a bearish candle that closes below the midpoint of the previous candle.
  • Indicates a potential reversal to a downtrend.

Bullish Inside Bar:
  • A smaller bullish or bearish candle completely within the range of the previous bearish candle.
  • Indicates a potential continuation or reversal to an uptrend.

Bearish Inside Bar:
  • A smaller bullish or bearish candle completely within the range of the previous bullish candle.
  • Indicates a potential continuation or reversal to a downtrend.
  • Triple Candlestick Patterns

Bullish Morning Star:
  • A bearish candle followed by a smaller-bodied candle (bullish or bearish), and then a larger bullish candle.
  • Indicates a potential reversal to an uptrend.

Bearish Evening Star:
  • A bullish candle followed by a smaller-bodied candle (bullish or bearish), and then a larger bearish candle.
  • Indicates a potential reversal to a downtrend.

How to Use?
Adding the Indicator:
  • Open TradingView and go to the Pine Script Editor.
  • Copy and paste the provided code into a new script.
  • Save and add the script to your chart.

Interpreting the Signals:
  • The indicator will highlight the patterns on the chart with specific labels.
  • Use these visual cues to make informed trading decisions based on potential reversals or continuations indicated by the patterns.

Customizing the Settings:
  • The indicator allows for customization of various settings through input options.
  • Adjust these settings according to your trading strategy and preferences.
Catatan Rilis:
Indicator: CS Patterns

Description
The "CS Patterns" indicator is a comprehensive tool for identifying various single, double, and triple candlestick patterns on a trading chart. This indicator is designed to help traders spot significant candlestick formations that can indicate potential market reversals or continuations. The indicator allows customization for pattern detection sensitivity and includes an optional look-back feature to consider historical price action.

Features
Single Candlestick Patterns:
  1. Bullish Hammer / Bearish Hanging Man: Identified by a small body, long lower shadow, and negligible upper shadow.
  2. Bullish Inverted Hammer / Bearish Shooting Star: Characterized by a small body, long upper shadow, and negligible lower shadow.
  3. Dragonfly Doji: Formed by a small body near the high of the candle with a long lower shadow.
  4. Gravestone Doji: Formed by a small body near the low of the candle with a long upper shadow.
  5. Standard Doji: A candle where the open and close are very close, indicating indecision.
  6. Long-legged Doji: Similar to a Standard Doji but with long upper and lower shadows.

Double Candlestick Patterns:
  1. Bullish Engulfing: A bullish candle that engulfs the previous bearish candle.
  2. Bearish Engulfing: A bearish candle that engulfs the previous bullish candle.
  3. Bullish Harami: A small bullish candle contained within the previous bearish candle.
  4. Bearish Harami: A small bearish candle contained within the previous bullish candle.
  5. Bullish Piercing Line: A bullish candle that closes above the midpoint of the previous bearish candle.
  6. Bearish Dark Cloud Cover: A bearish candle that closes below the midpoint of the previous bullish candle.
  7. Bullish Inside Bar: A bullish candle that is contained within the previous candle's range.
  8. Bearish Inside Bar: A bearish candle that is contained within the previous candle's range.

Triple Candlestick Patterns:
  1. Bullish Morning Star: A three-candle pattern where the first is bearish, the second has a small body (bullish or bearish), and the third is bullish, indicating a potential bullish reversal.
  2. Bearish Evening Star: A three-candle pattern where the first is bullish, the second has a small body (bearish or bullish), and the third is bearish, indicating a potential bearish reversal.

Customizable Settings:
  • Enable Look-Back Feature: Option to enable or disable the look-back feature for pattern detection.
  • Number of Candles to Look Back: Defines the number of previous candles to consider for pattern detection (default is 20).
  • Inputs
  • Enable Look-Back Feature: Boolean input to enable or disable the look-back feature (default is true).
  • Number of Candles to Look Back: Integer input to set the number of candles to look back for pattern detection (default is 20).
  • Hammer / Hanging Man: Boolean input to show or hide the Hammer and Hanging Man patterns.
  • Upper Wick Thresh % (Hammer/Hanging Man): Float input to set the threshold for negligible upper wick percentage.
  • Inv Hammer / Shooting Star: Boolean input to show or hide the Inverted Hammer and Shooting Star patterns.
  • Lower Wick Thresh % (Inv Hammer/Shooting Star): Float input to set the threshold for negligible lower wick percentage.
  • Dragonfly Doji: Boolean input to show or hide the Dragonfly Doji pattern.
  • Upper Wick Thresh % (Dragonfly Doji): Float input to set the threshold for small upper wick percentage.
  • Show Gravestone Doji: Boolean input to show or hide the Gravestone Doji pattern.
  • Lower Wick Thresh % (Gravestone Doji): Float input to set the threshold for small lower wick percentage.
  • Show Standard Doji: Boolean input to show or hide the Standard Doji pattern.
  • Show Long-legged Doji: Boolean input to show or hide the Long-legged Doji pattern.
  • Bullish Engulfing: Boolean input to show or hide the Bullish Engulfing pattern.
  • Bearish Engulfing: Boolean input to show or hide the Bearish Engulfing pattern.
  • Bullish Harami: Boolean input to show or hide the Bullish Harami pattern.
  • Bearish Harami: Boolean input to show or hide the Bearish Harami pattern.
  • Bull Piercing Line: Boolean input to show or hide the Bullish Piercing Line pattern.
  • Bear Dark Cloud Cover: Boolean input to show or hide the Bearish Dark Cloud Cover pattern.
  • Bullish Morning Star: Boolean input to show or hide the Bullish Morning Star pattern.
  • Bearish Evening Star: Boolean input to show or hide the Bearish Evening Star pattern.
  • Bullish Inside Bar: Boolean input to show or hide the Bullish Inside Bar pattern.
  • Bearish Inside Bar: Boolean input to show or hide the Bearish Inside Bar pattern.

Plotting
  • Patterns are plotted with distinct labels and colors to indicate the type of pattern detected.
  • Bullish patterns are labeled and colored in shades of green.
  • Bearish patterns are labeled and colored in shades of red.
  • This indicator provides a powerful tool for traders to identify key candlestick patterns and make informed trading decisions based on historical price action. The customizable look-back feature adds flexibility, allowing users to adjust the sensitivity of pattern detection according to their trading strategy.
Catatan Rilis:
Summary of Script Updates:
Look-Back Feature:
  • User Inputs: Added options to enable/disable look-back, set the look-back period, and show/hide high/low levels and labels.
  • Flexible Look-Back: Updated pattern detection to consider a variable look-back period (default 20 candles).

High/Low Display:
  • Calculations: Added calculations for the highest high and lowest low in the look-back period.
  • Dynamic Labels: Plots and deletes lines and labels for the highest high and lowest low based on user settings.

Pattern Detection:
  • Enhanced Logic: Updated all candlestick patterns to include look-back period confirmation and user-configurable settings.

These updates provide more flexibility and customization for traders, improving clarity in pattern detection and high/low levels within a specified look-back period.
Catatan Rilis:
Bullish and Bearish Engulfing Pattern Updates:

Bullish Engulfing:
  • Previous candle must be bearish; current candle must be bullish.
  • Current candle's open <= previous candle's close.
  • Current candle's close >= previous candle's open.
  • Added: Low of current or previous candle must be lower than previous N candles (if look-back enabled).

Bearish Engulfing:
  • Previous candle must be bullish; current candle must be bearish.
  • Current candle's open >= previous candle's close.
  • Current candle's close <= previous candle's open.
  • Added: High of current or previous candle must be higher than previous N candles (if look-back enabled).

These updates ensure stricter pattern validation and incorporate significant highs and lows when look-back is enabled.
Catatan Rilis:
Bullish Piercing Line and Bearish Dark Cloud Cover Patterns

Previous Version:
  • Bullish Piercing Line required the bullish candle to close above the midpoint of the previous bearish candle.
  • Bearish Dark Cloud Cover required the bearish candle to close below the midpoint of the previous bullish candle.

New Version:
  • Bullish Piercing Line now allows the close to be either above or below the midpoint if there is higher trading volume.
  • Bearish Dark Cloud Cover also allows the close to be either above or below the midpoint with higher trading volume.
  • Bullish Morning Star and Bearish Evening Star Patterns

Previous Version:
  • Bullish Morning Star required a bearish first candle, a small-bodied second candle, and a bullish third candle with specific open and close conditions.
  • Bearish Evening Star required a bullish first candle, a small-bodied second candle, and a bearish third candle with specific open and close conditions.

New Version:
  • Bullish Morning Star now includes variations like Dragonfly Doji, Gravestone Doji, Standard Doji, and Long-legged Doji for the second candle, with adjusted third candle conditions.
  • Bearish Evening Star also includes these variations for the second candle, with modified third candle conditions.

These updates make pattern detection more flexible and accurate by incorporating candlestick variations and adjusting conditions based on trading volume.
Catatan Rilis:
Functional Enhancements

Confirmation Candle Requirement:
  • Old Code: Directly plotted the pattern shape when the pattern was detected.
  • New Code: Plots the pattern shape only if the confirmation candle is valid (i.e., a bullish or bearish confirmation candle following the pattern). This change is applied to all patterns.

Pattern-Specific Changes for the Following Patterns:
  • Bullish Hammer / Bearish Hanging Man
  • Bullish Engulfing / Bearish Engulfing
  • Bullish Harami / Bearish Harami
  • Bullish Piercing Line / Bearish Dark Cloud Cover
  • Morning Star / Evening Star
  • Inverted Hammer / Shooting Star
  • Standard Doji / Dragonfly Doji / Gravestone Doji / Long-legged Doji

  • Old Code: Plotted the shapes directly if the pattern was detected.
  • New Code: Plots the shapes only if the bullish confirmation candle or bearish confirmation candle is valid.

Summary
The latest code version has introduced significant enhancements focused on validating patterns with confirmation candles before plotting shapes on the chart. This ensures that the patterns identified are more reliable and actionable.
Catatan Rilis:
Release Notes

New Enhancements and Bug Fixes
Engulfing Candle Enhancement:
  • The Engulfing Candle pattern now requires the engulfing candle to have the lowest low or highest high compared to the previous candle. This change ensures more accurate pattern detection and better trading signals.

Morning and Evening Star Enhancement:
  • For the Morning Star pattern, the Doji candle must now have the lowest low within the three-candle formation.
  • For the Evening Star pattern, the Doji candle must have the highest high within the three-candle formation.
  • This adjustment improves the reliability of these patterns by ensuring key characteristics are met.

Bullish and Bearish Harami Pattern Correction:
  • Corrected the code for Bullish and Bearish Harami patterns. The body of the Harami candle must now be three times smaller than the Mother candle.
  • This correction ensures the Harami patterns are detected correctly, providing more precise trading signals.

I hope these updates enhance your trading experience and provide more accurate and actionable insights.
Skrip terproteksi
Skrip ini dipublikasikan secara closed-source dan anda dapat menggunakannya dengan bebas. Anda dapat memfavoritkannya untuk digunakan pada grafik. Anda tidak dapat melihat atau mengubah kode sumbernya.
Pernyataan Penyangkalan

Informasi dan publikasi tidak dimaksudkan untuk menjadi, dan bukan merupakan saran keuangan, investasi, perdagangan, atau rekomendasi lainnya yang diberikan atau didukung oleh TradingView. Baca selengkapnya di Persyaratan Penggunaan.

Inggin menggunakan skrip ini pada chart?