CCI TickVolume Signal

by Danis in category Trend at 08/11/2017
Description

I remake a series of indicators (Rsi, Bolling Bands, CCI with TickVolume and HeikenAshi, ADX) and one main indicator from where can see trend (ADX, BollingerBands, XMA (one variant of MA) Point and figure, HeikenAshi, Candlestick Pattern)
The best one is a new interpretation of BollingerBands with a signal from angle tendency. this is until now the most precise indicator that can help to no-trade when the trend is in Range stage.
With this I make a cBot with SortoRatio 3,39 and SpotRatio 0,97 - that means a yield from 95% of trade signals.
I put here more screenshots from this indicators.
If you are interested, you can contact me at dp@ideadevelop.net for details about price and yield.

    [Indicator(IsOverlay = false, AccessRights = AccessRights.None)]
    public class Bandwidth : Indicator
    {
        [Parameter()]
        public DataSeries Source { get; set; }

        [Output("Main", Color = Colors.Yellow)]
        public IndicatorDataSeries bbdiff { get; set; }
        [Output("updiff", Color = Colors.Tomato)]
        public IndicatorDataSeries updiff { get; set; }
        [Output("dndiff", Color = Colors.Aqua)]
        public IndicatorDataSeries dndiff { get; set; }

        private Colors Cg, Cdg, Cr, Cdr, Co, bbmomC, emaC;

        private string bbmomt = string.Empty;
        private string emat = string.Empty;

        private BollingerBands Bbs;
        private SimpleMovingAverage Bema;

        protected override void Initialize()
        {
            Cg = Colors.LimeGreen;
            Cdg = Colors.Green;
            Co = Colors.Orange;
            Cr = Colors.Red;
            Cdr = Colors.DarkRed;

            Bbs = Indicators.BollingerBands(MarketSeries.Close, 21, 2.1, MovingAverageType.Simple);
            Bema = Indicators.SimpleMovingAverage(MarketSeries.Close, 4);
        }

        public override void Calculate(int index)
        {
            bbdiff[index] = (Bbs.Top[index] - Bbs.Bottom[index]) / Bbs.Main[index];
..........................................

 

Download
305 downloads
How to install
Notification Publishing copyrighted material is strictly prohibited. If you believe there is copyrighted material in this section you may use the Copyright Infringement Notification form to submit a claim.
Formula / Source Code
Language: C#
Trading Platform: cAlgocTrader
using System;
using cAlgo.API;
using cAlgo.API.Internals;
using cAlgo.API.Indicators;
using cAlgo.Indicators;

namespace cAlgo
{
    [Indicator(IsOverlay = false, TimeZone = TimeZones.UTC, AccessRights = AccessRights.None)]
    [Levels(-100, 0, 100)]

    public class DX_CCI_HA : Indicator
    {

        [Parameter("CCI Periods", DefaultValue = 34)]
        public int cciPeriods { get; set; }
        [Parameter("HA Color Change Candle #", DefaultValue = 3)]
        public int haColor { get; set; }

        [Output("Up Bar", Color = Colors.Green, PlotType = PlotType.Histogram, Thickness = 4)]
        public IndicatorDataSeries upBar { get; set; }

        [Output("Down Bar", Color = Colors.Red, PlotType = PlotType.Histogram, Thickness = 4)]
        public IndicatorDataSeries downBar { get; set; }

        [Output("CCI Line", Color = Colors.Bisque, PlotType = PlotType.Line, Thickness = 1)]
        public IndicatorDataSeries cciLine { get; set; }

        private Colors Cr, Cdr, Cg, Cdg, Co, cciC, hkaC;
        private string trendt = string.Empty;
        private string ccit = string.Empty;
        private string hkat = string.Empty;

        CommodityChannelIndex cci;
        HeikenAshi hak;

        protected override void Initialize()
        {
            Cg = Colors.Green;
            Cr = Colors.Red;
            Co = Colors.Orange;
            Cdr = Colors.DarkRed;
            Cdg = Colors.DarkGreen;

            cci = Indicators.CommodityChannelIndex(cciPeriods);
            hak = Indicators.GetIndicator<HeikenAshi>(1);
        }

        public override void Calculate(int index)
        {
            cciLine[index] = cci.Result[index];

            var pre_cci = cci.Result.Last(2);
            var cur_cci = cci.Result.Last(0);

            if (hak.xOpen[index] < hak.xClose[index])
            {
                downBar[index] = 0;
                upBar[index] = cci.Result[index];
            }
            else if (hak.xOpen[index] > hak.xClose[index])
            {
                upBar[index] = 0;
                downBar[index] = cci.Result[index];
            }

            cciC = ((cci.Result.HasCrossedAbove(-100, 1) && cur_cci > pre_cci) || (cci.Result.HasCrossedAbove(100.0, 1) && cur_cci > pre_cci)) ? Cg : ((cci.Result.HasCrossedBelow(-100.0, 1) && cur_cci < pre_cci) || (cci.Result.HasCrossedBelow(100, 1) && cur_cci < pre_cci)) ? Cr : Co;
            ccit = (cciC == Cg) ? "Bullish" : (cciC == Cr) ? "Bearish" : "Range";
            var lval = hak.xClose.Last(1) - hak.xOpen.Last(1);
            var val = hak.xClose.Last(0) - hak.xOpen.Last(0);
            hkaC = (hak.xOpen.Last(0) > hak.xClose.Last(0) && MarketSeries.Close[index] < hak.xClose.Last(0) && lval < val) ? Cdr : (hak.xOpen.Last(0) > hak.xClose.Last(0) && MarketSeries.Close[index] < hak.xClose.Last(0) && lval >= val) ? Cr : (hak.xOpen.Last(0) < hak.xClose.Last(0) && MarketSeries.Close[index] > hak.xClose.Last(0) && lval > val) ? Cdg : (hak.xOpen.Last(0) < hak.xClose.Last(0) && MarketSeries.Close[index] > hak.xClose.Last(0) && lval <= val) ? Cg : Co;
            hkat = (hkaC == Cr) ? "Sell" : (hkaC == Cdr) ? "sell" : (hkaC == Cg) ? "Buy" : (hkaC == Cdg) ? "buy" : "Wait";

            ChartObjects.DrawText("CCI", "Signal:" + "\t\t", StaticPosition.TopRight, Colors.Bisque);
            ChartObjects.DrawText("CCI1", ccit, StaticPosition.TopRight, cciC);
            ChartObjects.DrawText("HKA", "\nHkAshi:" + "\t\t", StaticPosition.TopRight, Colors.Bisque);
            ChartObjects.DrawText("HKA1", "\n" + hkat, StaticPosition.TopRight, hkaC);

        }

    }
}
Comments

Danis - November 08, 2017 @ 23:17

This indicator is just a example from DX indicators suite (ADX, CCI, TDI, BBands, Correlatins, Candlestick, HMA, MACD, Stochastic). all are with trend and signal analyse and very proficiently to use.

For detalis contact me at dp@ideadevelop.net

5