present
Đăng ký và nhận ưu đãi $50 cho lần mua đầu tiên
Trading product for Doji Engulf Chỉ báo, image 1
Doji Engulf
Chỉ báo
3 lượt tải
Phiên bản 1.0, Jul 2025
Windows, Mac
3
Cài đặt miễn phí

Mô tả

using cAlgo.API;

using cAlgo.API.Indicators;

using cAlgo.API.Internals;

using System;


namespace cAlgo.Indicators

{

[Indicator(TimeZone = TimeZones.UTC, AccessRights = AccessRights.None)]

public class DojiStrategyIndicator : Indicator

{

[Parameter("Kích thước Doji", DefaultValue = 0.05, MinValue = 0.01, Step = 0.01)]

public double DojiSize { get; set; }


[Parameter("Tỷ lệ Nến dài", DefaultValue = 0.7, MaxValue = 1, Step = 0.1)]

public double LongCandleRatio { get; set; }


[Parameter("Sử dụng Bộ lọc Khối lượng?", DefaultValue = false)]

public bool UseVolumeFilter { get; set; }


[Parameter("Chu kỳ Trung bình Động Khối lượng", DefaultValue = 24)]

public int VolumeMA { get; set; }


[Parameter("Chu kỳ RSI", DefaultValue = 14)]

public int RSIPeriod { get; set; }


[Parameter("Tỷ lệ Bấc so với Thân nến", DefaultValue = 2.5, MinValue = 1.0, Step = 0.1)]

public double WickToBodyRatio { get; set; }


private MovingAverage volumeMA;

private RelativeStrengthIndex rsi;


[Output("Tín hiệu Doji", Color = Colors.Orange, PlotType = PlotType.Points, Thickness = 2)]

public IndicatorDataSeries DojiSignal { get; set; }


protected override void Initialize()

{

if (UseVolumeFilter)

volumeMA = Indicators.MovingAverage(MarketSeries.TickVolume, VolumeMA, MovingAverageType.Simple);


rsi = Indicators.RelativeStrengthIndex(MarketSeries.Close, RSIPeriod);

}


public override void Calculate(int index)

{

double body = MarketSeries.Close[index] - MarketSeries.Open[index];

double range = MarketSeries.High[index] - MarketSeries.Low[index];

double abody = Math.Abs(body);

double ratio = abody / range;


bool isDoji = abody <= range * DojiSize;

bool goStar = isDoji && (!UseVolumeFilter || MarketSeries.TickVolume[index] > volumeMA.Result[index]);


if (goStar && IsHigherTimeFrame(out int timeFrameNumber, out string label))

{

DojiSignal[index] = MarketSeries.Close[index]; // Đánh dấu Doji trên biểu đồ

Chart.DrawIcon("Doji" + TimeFrame.ToString() + index, ChartIconType.Diamond, index, MarketSeries.Close[index], Color.Orange);


// Làm nổi bật mức cao và thấp của nến Doji bằng các đường thẳng liền mạch kéo dài qua 3 nến tiếp theo

HighlightDojiHighLow(index, timeFrameNumber, label);

}


// Phát hiện phân kỳ SMT hiện được áp dụng cho tất cả các khung thời gian

DetectSMTDivergence(index);

}


private bool IsHigherTimeFrame(out int timeFrameNumber, out string label)

{

timeFrameNumber = 0;

label = string.Empty;


if (TimeFrame == TimeFrame.Minute15)

{

timeFrameNumber = 15;

label = "0.25";

return true;

}

else if (TimeFrame == TimeFrame.Minute30)

{

timeFrameNumber = 30;

label = "0.5";

return true;

}

else if (TimeFrame == TimeFrame.Minute45)

{

timeFrameNumber = 45;

label = "0.75";

return true;

}

else if (TimeFrame == TimeFrame.Hour)

{

timeFrameNumber = 1;

label = "1";

return true;

}

else if (TimeFrame == TimeFrame.Hour2)

{

timeFrameNumber = 2;

label = "48";

return true;

}

else if (TimeFrame == TimeFrame.Hour4)

{

timeFrameNumber = 4;

label = "4";

return true;

}

else if (TimeFrame == TimeFrame.Daily)

{

timeFrameNumber = 24;

label = "24";

return true;

}

else if (TimeFrame == TimeFrame.Weekly)

{

timeFrameNumber = 168;

label = "W";

return true;

}

else if (TimeFrame == TimeFrame.Monthly)

{

timeFrameNumber = 720;

label = "M";

return true;

}


return false;

}


private void HighlightDojiHighLow(int dojiIndex, int timeFrameNumber, string label)

{

double dojiHigh = MarketSeries.High[dojiIndex];

double dojiLow = MarketSeries.Low[dojiIndex];


// Vẽ các đường ngang liền mạch tại mức cao và thấp của nến Doji kéo dài qua 3 nến tiếp theo

Chart.DrawTrendLine("DojiHighLine" + TimeFrame.ToString() + dojiIndex, dojiIndex, dojiHigh, dojiIndex + 3, dojiHigh, Color.Blue, 2, LineStyle.Solid).IsInteractive = true;

Chart.DrawTrendLine("DojiLowLine" + TimeFrame.ToString() + dojiIndex, dojiIndex, dojiLow, dojiIndex + 3, dojiLow, Color.Red, 2, LineStyle.Solid).IsInteractive = true;


// Thêm số khung thời gian hoặc văn bản nhãn bên cạnh đường màu xanh

Chart.DrawText("TimeFrameHigh" + TimeFrame.ToString() + dojiIndex, label, dojiIndex + 3, dojiHigh, Color.Green).IsInteractive = true;

}


private void DetectSMTDivergence(int index)

{

// Kiểm tra xem mức cao hoặc thấp hiện tại có tạo thành phân kỳ với RSI không

double currentHigh = MarketSeries.High[index];

double currentLow = MarketSeries.Low[index];


double prevHigh = MarketSeries.High[index - 1];

double prevLow = MarketSeries.Low[index - 1];


double currentRSI = rsi.Result[index];

double prevRSI = rsi.Result[index - 1];


bool isWickDivergence = IsWickDivergence(index, currentHigh, currentLow, prevHigh, prevLow);


if (isWickDivergence)

{

// Phân kỳ giảm giá: Giá tạo đỉnh cao hơn, RSI tạo đỉnh thấp hơn

if (currentHigh > prevHigh && currentRSI < prevRSI)

{

// Đánh dấu phân kỳ trên biểu đồ với định danh duy nhất cho khung thời gian này

Chart.DrawIcon("BearishDivergence" + TimeFrame.ToString() + index, ChartIconType.DownArrow, index, currentHigh, Color.Red);

}


// Phân kỳ tăng giá: Giá tạo đáy thấp hơn, RSI tạo đáy cao hơn

if (currentLow < prevLow && currentRSI > prevRSI)

{

// Đánh dấu phân kỳ trên biểu đồ với định danh duy nhất cho khung thời gian này

Chart.DrawIcon("BullishDivergence" + TimeFrame.ToString() + index, ChartIconType.UpArrow, index, currentLow, Color.Green);

}

}

}


private bool IsWickDivergence(int index, double currentHigh, double currentLow, double prevHigh, double prevLow)

{

double currentBody = Math.Abs(MarketSeries.Close[index] - MarketSeries.Open[index]);

double currentRange = currentHigh - currentLow;


double prevBody = Math.Abs(MarketSeries.Close[index - 1] - MarketSeries.Open[index - 1]);

double prevRange = prevHigh - prevLow;


// Xác định xem nến hiện tại có thân nhỏ và bấc dài không

bool currentHasLongWicks = (currentHigh - MarketSeries.Close[index]) > currentBody * WickToBodyRatio &&

(MarketSeries.Open[index] - currentLow) > currentBody * WickToBodyRatio;


// Xác định xem nến trước đó có thân nhỏ và bấc dài không

bool prevHasLongWicks = (prevHigh - MarketSeries.Close[index - 1]) > prevBody * WickToBodyRatio &&

(MarketSeries.Open[index - 1] - prevLow) > prevBody * WickToBodyRatio;


return currentHasLongWicks || prevHasLongWicks;

}

}

}

Tóm tắt

AI summary
Doji Engulf is a technical indicator designed for use on multiple higher timeframes including 1 hour, 4 hours, and daily charts. It identifies Doji candlestick patterns—candles with small bodies relative to their range—and validates these signals by checking volume filters and relative strength index (RSI) conditions. The indicator marks detected Doji candles on the chart with orange diamond icons and highlights their high and low prices with solid horizontal lines extending over subsequent candles. It also detects Smart Money Technique (SMT) divergences by comparing price highs and lows with RSI values, marking bullish and bearish divergences with green up arrows and red down arrows respectively. Parameters allow customization of Doji size, candle body ratios, volume filtering, volume moving average period, RSI period, and wick-to-body ratio. The indicator supports multiple timeframes from 15 minutes up to monthly, adapting its analysis accordingly. It provides visual cues directly on the trading chart to assist traders in identifying potential reversal or continuation signals based on Doji patterns and divergence analysis.
Hồ sơ chỉ báo

Đánh giá của khách hàng

0.0
Đánh giá: 0
Đánh giá của khách hàng
Sản phẩm này chưa có đánh giá nào. Bạn đã dùng thử chưa? Hãy là người đầu tiên chia sẻ với mọi người!

Thảo luận

Câu hỏi thường gặp

Các sản phẩm có sẵn trên cTrader Store, bao gồm bot giao dịch, chỉ báo và plugin, được cung cấp bởi các nhà phát triển bên thứ ba và chỉ nhằm mục đích cung cấp thông tin và tiếp cận kỹ thuật. cTrader Store không phải là nhà môi giới và không cung cấp lời khuyên đầu tư, khuyến nghị cá nhân hay bất kỳ đảm bảo nào về hiệu suất trong tương lai.

Sản phẩm khác của tác giả này

Chỉ báo
The Session Golden Hours indicator is designed for serious traders looking to visualize high-probability

Bạn cũng có thể thích

Chỉ báo
Key Levels
Market Structure
+1
Sessions, ICT killzones, multi-ORB and previous levels. One clean, no-repaint cTrader overlay.
Chỉ báo
RSI
RSI on the main chart with 45/55 momentum levels, overbought/oversold levels, averaged RSI, and multi-timeframe support.
Logo "VA Footprint"
Hàng đầu
4.5
(4)
từ $19
Chỉ báo
SMC
Prop
+5
VA Footprint replaces your chart with a order flow one, the most precise way to read the market.
Chỉ báo
Prop
Forex
+3
Price Change Bundle 3-in-1 Levels • Bars • Histogram. Secret of Price Change
Chỉ báo
RSI
Minimalist RSI dots with dynamic colors for instant momentum and extreme zone recognition.
Logo "KANDIKA HEAT MAP"
Hàng đầu
4.6
(5)
$19
Chỉ báo
Color-Based Market Pressure & Volatility Visualizer The Kandika Heatmap Indicator
Chỉ báo
Market Structure
Support & Resistance
Auto-centers price when it moves beyond threshold. Adjustable zoom. Works on any chart type. Never lose price again.
Chỉ báo
Prop
ZigZag
+5
All-in-One ICT/SMC Institutional Framework — Ranges, Structure, Liquidity, Fibonacci & Time Engine.
Chỉ báo
Smart Signal Reversal Trend + Patterns
Chỉ báo
Imbalance
Fair Value Gap
+1
Multi-symbol, multi-timeframe Fair Value Gaps in one panel.
Chỉ báo
Grid
Prop
+5
Logarithmic Framework by LudwigICT
Chỉ báo
ATR
RSI
+19
Multi-timeframe heatmap scoring Direction, Strength & Volatility at a glance!
Logo "Dem"
Hàng đầu
4.2
(4)
$20
Chỉ báo
Forex
BTCUSD
+5
Scalping indicator for Renko 100 using EMAs to show trend and entry zones with clear colored rectangles.
Chỉ báo
Moving Average
Simple moving-average crossover markers for identifying potential trend changes directly on a cTrader chart.
Chỉ báo
BOS
CHOCH
+5
A professional-grade cTrader indicator for traders following the Inner Circle Trader (ICT) methodology.
Chỉ báo
Prop
Forex
+9
Trend Sniper — session-based tool highlighting live session ranges and adaptive Custom line.
Chỉ báo
MACD
Signal
+1
Version 1.2: Advanced Trend Detection & Visualization System
Chỉ báo
Supertrend
Moving Average
Easy Trade: Trend & Breakout Indicator for cTrader

Giá

3
Cài đặt miễn phí