Need someone to develop Rubicons CCI-Cross indicator

If you need an Indicator or Signal developed or translated from other language, please post all Indicator development REQUESTS to this section here.

Moderator: admin

Need someone to develop Rubicons CCI-Cross indicator

Postby Rubicons » Thu Mar 18, 2010 11:03 pm

I would like someone to please develop this oscillator, which I call "Rubicons CCI-Cross" and share it with the group here.

The Commodity Channel Index (CCI) is an oscillator originally developed by Donald Lambert and featured in his book "Commodities Channel Index". The CCI like most oscillators, helps to determine overbought and oversold levels. There is an interesting variant to the standard set-up that I have been using succesfully for some time and would like to share with you.

What is Rubicons CCI-Cross: Basically it is a standard 10 Period CCI with a 3-EMA exponential moving average layered over it. In addition, there are two horizontal lines for resistance and support at the +100-Level and -100-Level respectfully. If possible, having the ability to select line colors would be great as many trade on different backgrounds - for example I trade on a black background.

How to use it: In addition to standard angle and separation (and divergence) signals are best given when they occur above and below the +100 and -100 Levels first by a cross of the 3-EMA with the CCI-10, and then confirmed when the 3-EMA also crosses the 100 and 0 level horizontal lines either long or short. For example, a 3-EMA cross from above and heading south through the +100 Level confirms a Short. Likewise, a 3-EMA cross from below heading north through the -100-Level confirms a Long.

This indicator should of course be confirmed with related Price Action and any other tools you may wish to use. However, I have found this to work on most timeframes and gives you an earlier signal (heads-up) than many others.

Thanks!
Last edited by Rubicons on Fri Mar 19, 2010 12:21 pm, edited 1 time in total.
Rubicons
 
Posts: 4
Joined: Thu Mar 18, 2010 10:27 pm

Re: Need someone to develop Rubicons CCI-Cross indicator

Postby Nikolay.Gekht » Fri Mar 19, 2010 10:33 am

Thank for your idea. I'll try to develop an implementation in a few days.
Nikolay.Gekht
FXCodeBase: Site Admin
 
Posts: 1235
Joined: Wed Dec 16, 2009 6:39 pm
Location: Cary, NC

Re: Need someone to develop Rubicons CCI-Cross indicator

Postby Rubicons » Mon Mar 22, 2010 12:25 pm

That's great.

If you have any questions pls don't hesitate to ask. Also if it helps, when I set this up manually (each time!) I use a solid red line as +100, a solid green line as -100 and insert a grey dotted line at the zero level (as some systems also use the zero level for entry/exits). The CCI-10 is also green and the CCI-3MVA is red. Of course the option to choose colors and line styles would work best for everyone's different needs, if that's possible.

Once you have the indicator, I will be happy to provide additional instructions to the group as how to best use it as well.

Thanks.
Rubicons
 
Posts: 4
Joined: Thu Mar 18, 2010 10:27 pm

Re: Need someone to develop Rubicons CCI-Cross indicator

Postby Nikolay.Gekht » Mon Mar 22, 2010 2:38 pm

Did I get your system right?

rubcci.png


If yes, I'll prepare an indicator and alert for the new version of the Marketscope shortly.

It will show the both indicators, levels, draws arrows on the cross points and highlight an area between +100 and -100 lines.
Nikolay.Gekht
FXCodeBase: Site Admin
 
Posts: 1235
Joined: Wed Dec 16, 2009 6:39 pm
Location: Cary, NC

Re: Need someone to develop Rubicons CCI-Cross indicator

Postby Rubicons » Mon Mar 22, 2010 3:03 pm

Hi Nikolay,

You nailed it!

That is exactly what I use now. It is of course (like all indicators/oscillators) a tool for which I look for confirmation from price action, etc. However, I find it's my best tool to give me a heads up to start watching the trade. If it's not above or below, I don't usually watch (with occassional exceptions of course, like news, big 00 numbers, etc).

Regarding the enhancements you propose...as for me I'm happy with it the way it is (as I'm used to that look). However, if you could make this version available now as a ".lua" file and then add the enhancements later for the next release of Marketscope - that would be really great.

Let me know what you think.
Thx again!
Rubicons
 
Posts: 4
Joined: Thu Mar 18, 2010 10:27 pm

Re: Need someone to develop Rubicons CCI-Cross indicator

Postby Nikolay.Gekht » Wed Mar 24, 2010 8:35 pm

Sorry for delay.

What could I do in the current version:
1) The indicator displays CCI(10) in green and EMA(CCI(10), 3) in red.
2) It also draws to lines: red +100 and green -100
3) It also draws bars in case the EMA crossed red or green lines AND CCI also crosses them in the previous 5 periods.

rubcci.PNG


RubCCI.lua
(3.37 KiB) Downloaded 675 times


If you don't like bars, just remove lines I marked in the code below (look for "-- remove")

Code: Select all
-- Indicator profile initialization routine
-- Defines indicator profile properties and indicator parameters
-- TODO: Add minimal and maximal value of numeric parameters and default color of the streams
function Init()
    indicator:name("Rubicon CCI");
    indicator:description("");
    indicator:requiredSource(core.Bar);
    indicator:type(core.Oscillator);

    indicator.parameters:addInteger("CCI_N", "CCI parameter", "No description", 10);
    indicator.parameters:addInteger("EMA_N", "EMA parameter", "No description", 3);
    indicator.parameters:addColor("CCI_color", "Color of CCI", "Color of CCI", core.rgb(0, 255, 0));
    indicator.parameters:addColor("EMA_color", "Color of EMA", "Color of EMA", core.rgb(255, 0, 0));
end

-- Indicator instance initialization routine
-- Processes indicator parameters and creates output streams
-- TODO: Refine the first period calculation for each of the output streams.
-- TODO: Calculate all constants, create instances all subsequent indicators and load all required libraries
-- Parameters block
local CCI_N;
local EMA_N;

local source = nil;

-- Streams block
local CCI = nil;
local EMA = nil;
local BARL = nil;
local BARS = nil;
local L1 = nil;
local L2 = nil;
local _CCI = nil;
local _EMA = nil;

-- Routine
function Prepare()
    CCI_N = instance.parameters.CCI_N;
    EMA_N = instance.parameters.EMA_N;
    source = instance.source;

    local name = profile:id() .. "(" .. source:name() .. ", " .. CCI_N .. ", " .. EMA_N .. ")";
    instance:name(name);

    L1 = instance:addStream("L1", core.Line, name .. ".L1", "L1", core.rgb(255, 0, 0), 0);
    L2 = instance:addStream("L2", core.Line, name .. ".L2", "L2", core.rgb(0, 255, 0), 0);
    -- remove two lines below if don't want bars
    BARS = instance:addStream("BS", core.Bar, name .. ".BS", "BS", core.rgb(255, 0, 0), 0);
    BARL = instance:addStream("BL", core.Bar, name .. ".BL", "BL", core.rgb(0, 255, 0), 0);

    _CCI = core.indicators:create("CCI", source, CCI_N);
    _EMA = core.indicators:create("EMA", _CCI.DATA, EMA_N);
    CCI = instance:addStream("CCI", core.Line, name .. ".CCI", "CCI", instance.parameters.CCI_color, _CCI.DATA:first());
    CCI:addLevel(-100);
    CCI:addLevel(0);
    CCI:addLevel(100);
    EMA = instance:addStream("EMA", core.Line, name .. ".EMA", "EMA", instance.parameters.EMA_color, _EMA.DATA:first());
end

-- Indicator calculation routine
-- TODO: Add your code for calculation output values
function Update(period, mode)
    local i;
    _CCI:update(mode);
    _EMA:update(mode);
    L1[period] = 100;
    L2[period] = -100;
    if period >= _CCI.DATA:first() then
        CCI[period] = _CCI.DATA[period];
    end
    if period >= _EMA.DATA:first() then
        EMA[period] = _EMA.DATA[period];
    end
    -- remove from here if you don't like bars
    if period >= _EMA.DATA:first() + 6 and period >= _CCI.DATA:first() + 6 then
        if core.crossesOver(_EMA.DATA, -100, period) then
            for i = period, period - 5, -1 do
                if core.crossesOver(_CCI.DATA, -100, i) then
                    BARL[period] = -75;
                    break;
                end
            end
        elseif core.crossesUnder(_EMA.DATA, 100, period) then
            for i = period, period - 5, -1 do
                if core.crossesUnder(_CCI.DATA, 100, i) then
                    BARS[period] = 75;
                    break;
                end
            end
        end
    end
    -- remove to here if you don't like bars
end


Want will I be able to do in the new release of marketscope?
1) highlight area between +100 and -100 lines
2) replace bars with arrows pointed below and above +100/-100 lines.
Nikolay.Gekht
FXCodeBase: Site Admin
 
Posts: 1235
Joined: Wed Dec 16, 2009 6:39 pm
Location: Cary, NC

Re: Need someone to develop Rubicons CCI-Cross indicator

Postby Nikolay.Gekht » Sun Apr 11, 2010 9:11 pm

Please find the final version of the indicator here: viewtopic.php?f=17&t=613
Nikolay.Gekht
FXCodeBase: Site Admin
 
Posts: 1235
Joined: Wed Dec 16, 2009 6:39 pm
Location: Cary, NC

Re: Need someone to develop Rubicons CCI-Cross indicator

Postby pipsqueak » Thu Apr 15, 2010 7:35 am

This great I had noticed the power of the CCI also, but hadn't (or wasn't smart enough) to see the ema possibility. Just the fact that a sell is highly likely when the CCI crosses the +100 with a negative slope or d(CCI)/dt =negative. A buy signal is highly likely when the CCI crosses the -100 with a positive slope d(CCI)/dt. I saw that this signal could be confirmed with a positive slope on the MACD siganl for a buy and a negative slope for a sell.

Good analysis!
pipsqueak
 
Posts: 21
Joined: Thu Apr 15, 2010 7:23 am

Re: Need someone to develop Rubicons CCI-Cross indicator

Postby voodoo » Sun Jun 05, 2011 9:15 am

Hi,

Im just wondering if you could develop a strategy for auto trading using this indicator... with specific entry and exit orders, with one order at a time until previous order closed. able to set stop orders, and any thing else that would make it an excellent strategy. of course you can have the option of the entrys and exits as listed by rubicons such as exit as soon as ema crosses the CCi line, but can also change these as necessary...

Thanks for the great work...
voodoo
 
Posts: 1
Joined: Sun Jun 05, 2011 9:01 am


Next

Return to Indicator and Signal Requests

Who is online

Users browsing this forum: No registered users and 32 guests