Program Trading: Trade Entry

Bias

Just a thought about Bias if I understand the spec correctly.
If you are determining the Bias in order to automatically decide which side of the market to trade, then I think there needs to be a manual override for forcing the bias.
The reason for this is that there are days when the market fundamentals change because of some important news and (e.g.) a previously strong market will become weak before the longer term indicators can respond.

Glenn
 
Suggestions:-
1. Use the macci + 3 sma of it for crossover signals, if only for testing. Avoids many of the issues you describe and gives good signals.
2. If the 10 + 30 min or the 10 + 60 min are in agreement then take that as the market direction.
If the 1 + 3 minute or 1 + 5 minute are in agreement with the above, then take that as the entry signal.
3.
BIAS- If the direction is up but we are above the alert area, then we shouldn't take a long. Agreed

- If the direction is flat & we are below the alert area, should we bias long or wait for the turn up ?
Depends if you stick with a single line or use a signal line. If the former then Yes

- Do we always need the backup of all 3 ? If not, which specific scenarios should we consider ?
See 2. above.

Entry- do we need to look for any specific candle formation on the 1 min ? NO

- can we say OK for a timeframe if it turns up, even if it's between the alert zones ? YES

- can we say OK for a timeframe if it is flat & below the lower alert zone ? Don't inderstand this question.

- do we need backup of all 3 lower time frames ? if not, which specific scenarios should we consider ? See 2. above.

- do we need to consider VIX ? Is VIX even applicable at 1 min timeframes ? Imho, NO.


Glenn

Hi Glenn

Its great that you are helping with the thread. Is the following simple code modifications to Iraj Macci Send along the lines of what you mean by adding a 3sma plot to it? (added Plot4 etc.)

Inputs: Length1(6), Length2(5);
Vars:CCIval(0),CCIavg(0),Name(GetSymbolName + NumToStr(BarInterval,0));
Vars:CCIar(0);

CCIval = CCI(Length1);
CCIavg = average(CCIval, Length2);

value1 = GVSetNamedFloat(Name,CCIavg);

CCIar = (CCIavg[0]+CCIavg[1]+CCIavg[2])/3;

Plot1 (CCIavg,"CCI Avg",black,white);
Plot4 (CCIar,"CCI Aar",black,white);

if lastbaronchart then print(getsymbolname," ",Name);

Plot2(+100,"O/B",darkred);
Plot3(-100,"O/S",darkred);



Cheers
Steve
 
Hi Glenn

Its great that you are helping with the thread. Is the following simple code modifications to Iraj Macci Send along the lines of what you mean by adding a 3sma plot to it? (added Plot4 etc.)

Inputs: Length1(6), Length2(5);
Vars:CCIval(0),CCIavg(0),Name(GetSymbolName + NumToStr(BarInterval,0));
Vars:CCIar(0);

CCIval = CCI(Length1);
CCIavg = average(CCIval, Length2);

value1 = GVSetNamedFloat(Name,CCIavg);

CCIar = (CCIavg[0]+CCIavg[1]+CCIavg[2])/3;

Plot1 (CCIavg,"CCI Avg",black,white);
Plot4 (CCIar,"CCI Aar",black,white);

if lastbaronchart then print(getsymbolname," ",Name);

Plot2(+100,"O/B",darkred);
Plot3(-100,"O/S",darkred);



Cheers
Steve

Hi Steve
Deosn't look right to me, you are taking an average of Macci averages rather than an average of the CCI.

What I would do is add a new Input of Length3, having value of 3.
Then replace your CCIar calc line with this line of code:-
CCIar = average(CCIval, Length3);


OOPS - just realised that I explained it incorrectly. It should be a 3sma of the CCI, not the MAcci. Sorry folks !!


Glenn
 
Last edited:
Hi Steve
Deosn't look right to me, you are taking an average of Macci averages rather than an average of the CCI.

What I would do is add a new Input of Length3, having value of 3.
Then replace your CCIar calc line with this line of code:-
CCIar = average(CCIval, Length3);

Glenn

Ahh; I see. I have changed it as you suggest. It's more sensitive this way

Thanks
Steve
 
Here's the code guys...

#TT_ENTRYPOINT

Code:
// This indicator will return a value based on analyzing the $INDU 
// It should be applied to the 60,30,10,5,3,1 minute $INDUs
// FlatPercentage is the percentage move we conside flat

// Not Included
// 1 - . Use the macci + 3 sma of it for crossover signals
// 2 - Look for turn of an indicator in the mid zone on the lower time frames.

Inputs : OBThreshold(100), OSThreshold(-100),CycleLength(6), Smoothing(5), 
		OBAlert(80), OSAlert(-80), FlatPercentage(5); 

Vars : LoopCount(0), RTNVal(0), FlatAmt(0),ReturnCode(0), Action(" "),
	Zone60("", data6),Zone30("", data5),Zone10("", data4), 
	Zone5("", data3), Zone3("", data2), Zone1("", data1), 
	Direction60("", data6), Direction30("", data5), Direction10("", data4), 
	Direction5("", data3), Direction3("", data2), Direction1("", data1), 
	Bias60(" "), Bias30(" "), Bias10(" "),Bias(" "),
	Trigger5(" "), Trigger3(" "), Trigger1(" "),Trigger(""), 
	CycleHistory60(0, data6),CycleHistory30(0, data5),CycleHistory10(0, data4),
	CycleHistory5(0, data3),CycleHistory3(0, data2),CycleHistory1(0,data1);

// If FlatAmt hasn't been calculated yet - do that now...
	
If FlatAmt = 0 then
	FlatAmt = ((OBThreshold - OSThreshold) / 100) * FlatPercentage; 
	
// Calculate the indicator for the timeframes

CycleHistory60 = TTCycle(CycleLength,Smoothing) data6;
CycleHistory30 = TTCycle(CycleLength,Smoothing) data5;
CycleHistory10 = TTCycle(CycleLength,Smoothing) data4;
CycleHistory5 = TTCycle(CycleLength,Smoothing) data3;
CycleHistory3 = TTCycle(CycleLength,Smoothing) data2;
CycleHistory1 = TTCycle(CycleLength,Smoothing) data1;

// Plot cycle 1 as this indicator is for the 1 minute

Plot1(CycleHistory1, "Cycle"); 
Plot2(OBThreshold,"OverBought"); 
Plot3(OSThreshold,"Oversold"); 
plot4(0,"Zero");
Plot5(OBAlert,"Alert");
Plot6(OSAlert,"Alert");

// Now that we have cycle history - we sl pass ihould call another function (TTDirection) that should tell us which way
// The indicator is going - we'ln the array & that function will tell us up, down, flat, etc
// That function can be improved over time

// Direction - Indicates direction
//  + moving up
//  - moving down
//  F flat (should not indicate that it is perfecly flat but within a tolerance - say less than 10% angle)

Direction60 = TT_CYCLE_DIRECTION(FlatAmt, CycleHistory60); 
Direction30 = TT_CYCLE_DIRECTION(FlatAmt, CycleHistory30); 
Direction10 = TT_CYCLE_DIRECTION(FlatAmt, CycleHistory10); 
Direction5 = TT_CYCLE_DIRECTION(FlatAmt, CycleHistory5); 
Direction3 = TT_CYCLE_DIRECTION(FlatAmt, CycleHistory3); 
Direction1 = TT_CYCLE_DIRECTION(FlatAmt, CycleHistory1); 

// Now that we have direction, we can look to see if we are OB, OS (based on inputs above) as well as direction 
// and set 2 global variables for the 60 macci as follows :
// Zone - Indicates where it is
// MD - Mid
// AB - in upper alert zone
// OB - Overbrought
// AS - in lower alert zone
// OS - Oversold

Zone60 = TT_CYCLE_AREA(OBThreshold, OSThreshold, OBAlert, OSAlert, CycleHistory60);
Zone30 = TT_CYCLE_AREA(OBThreshold, OSThreshold, OBAlert, OSAlert, CycleHistory30);
Zone10 = TT_CYCLE_AREA(OBThreshold, OSThreshold, OBAlert, OSAlert, CycleHistory10);
Zone5 = TT_CYCLE_AREA(OBThreshold, OSThreshold, OBAlert, OSAlert, CycleHistory5);
Zone3 = TT_CYCLE_AREA(OBThreshold, OSThreshold, OBAlert, OSAlert, CycleHistory3);
Zone1 = TT_CYCLE_AREA(OBThreshold, OSThreshold, OBAlert, OSAlert, CycleHistory1);

// calculate bias for higher timeframes

Bias60 = TT_CYCLE_BIAS(Zone60,Direction60);
Bias30 = TT_CYCLE_BIAS(Zone30,Direction30);
Bias10 = TT_CYCLE_BIAS(Zone10,Direction10);

If Bias10 = Bias60 or Bias10 = Bias30 then Bias = Bias10 else Bias = "None";

// calculate triggers for lower timeframes and determine trigger

Trigger5 = TT_CYCLE_TRIGGER(Zone5, Direction5);
Trigger3 = TT_CYCLE_TRIGGER(Zone3, Direction3);
Trigger1 = TT_CYCLE_TRIGGER(Zone1, Direction1);

If Trigger1 = Trigger5 or Trigger1 = Trigger3 then Trigger = Trigger1 else Bias = "None";

// determine action to take (if any)
	
Action = "None";
if Bias = "Short" and Trigger = "Short" then Action = "SellShort";
if Bias = "Long" and Trigger = "Long" then Action = "Buy";

	
if Action = "SellShort" then begin
//	Plot1(Low);
	Alert("Sell Short");
//	ReturnCode = TT_GET_ARRAY;
end;
	
if Action = "Buy" then begin
//	Plot2(High);
	Alert("Go Long");
//	ReturnCode = TT_GET_ARRAY;
end ;	

// Print data 
	

	Print(FormatDate( "dd MMM yy", ElDateToDateTime( Date )), " ", FormatTime( "hh:mm", ElTimeToDateTime( Time )) , " Zone 60 = ", Zone60, ", Dir 60 = ",	Direction60,
		", Zone 30 = ", Zone30, ", Dir 30 = ", Direction30,
		", Zone 10 = ", Zone10, ", Dir 10 = ", Direction10,
		", Zone 5 = ", Zone5, ", Dir 5 = ", Direction5,
		", Zone 3 = ", Zone3, ", Dir 3 = ", Direction3,
		", Zone 1 = ", Zone1, ", Dir 1 = ", Direction1,
		", Bias = ", Bias, ", Trigger = ", Trigger, ", Action = ", Action);
If Time <> Time[1] and (Action = "Buy" or Action = "SellShort") then begin
	Print(" Cycles ", CycleHistory60, " ", CycleHistory30, " ", CycleHistory10, 
		" ", CycleHistory5, " ", CycleHistory3, " ", CycleHistory1);
end;

// For testing only - if this is the last bar on the chart - output the array
// Switch this off if running in real time
	
//if LastBarOnChart then 
//	ReturnCode = TT_GET_ARRAY;

TT_CYCLE is just the MACCi, so I won't post that.


TT_CYCLE_DIRECTION
Code:
// Pass back a string to indicate the direction of the cycle
//
// Returns :
// + - rising
// - - declining
// F - Flat

Inputs : FlatAmt(numeric), CycleHistory(numeric);

If CycleHistory > CycleHistory[1] + FlatAmt then
	TT_CYCLE_DIRECTION = "+"
	else if CycleHistory < CycleHistory[1] - FlatAmt then
		TT_CYCLE_DIRECTION = "-"
else
	TT_CYCLE_DIRECTION = "F";

TT_CYCLE_AREA

Code:
/ Pass back a string to say where in the cycle the indicator is
//
// Returns :
// MD - Mid
// AB - in upper alert zone
// OB - Overbrought
// AS - in lower alert zone
// OS - Oversold

inputs : OBThreshold(numeric), OSThres hold(numeric), OBAlert(numeric), OSAlert(numeric),
		 CycleHistory(numeric);

// I know nested ifs are faster but I want to keep the code simple
// if performance becomes an issue, we can tune this

if CycleHistory < OBAlert and CycleHistory > OSAlert then
	TT_CYCLE_AREA = "MD";

if CycleHistory >= OBAlert and CycleHistory < OBThreshold then
	TT_CYCLE_AREA = "AB";

if CycleHistory >= OBThreshold then
	TT_CYCLE_AREA = "OB";

if CycleHistory <= OSAlert and CycleHistory > OSThreshold then 
	TT_CYCLE_AREA = "AS";

if CycleHistory <= OSThreshold then
	TT_CYCLE_AREA = "OS";

TT_CYCLE_BIAS

Code:
// Take previously calculated zone & direction and give back bias
//
// If OS : Long
// If in OS alert zone & + or flat : long
// If in the middle : follow direction
// If in OB alert zone & - or flat : short

inputs : Zone(string), Direction(string);

TT_CYCLE_BIAS = "None";

Switch(Zone) begin
	Case "OB" : TT_CYCLE_BIAS = "Short";
    Case "AB" : if Direction <> "+" then TT_CYCLE_BIAS = "Short";
	Case "MD" :
	Switch(Direction) 
		Begin
  		Case "F" : TT_CYCLE_BIAS = "None";
        Case "+" : TT_CYCLE_BIAS = "Long";
		Case "-" : TT_CYCLE_BIAS = "Short";
		end;
	Case "AS" : if Direction <> "-" then TT_CYCLE_BIAS = "Long";
	Case "OS" : TT_CYCLE_BIAS = "Long";
end;

TT_CYCLE_TRIGGER

Code:
// Take previously calculated zone & direction and give back trigger
// Sorry about the commented code - I'm still mulling it over
// 

inputs : Zone(string), Direction(string);

TT_CYCLE_TRIGGER = "None";

Switch(Zone) begin
	Case "OB" : TT_CYCLE_TRIGGER = "Short";
//    Case "AB" : if Direction = "+" then TT_CYCLE_TRIGGER = "None" else TT_CYCLE_TRIGGER = "Short";
//	Case "MD" :
//	Switch(Direction) 
//		Begin
//		Case "F" : TT_CYCLE_TRIGGER = "None";
//        Case "+" : TT_CYCLE_TRIGGER = "Long";
//		Case "-" : TT_CYCLE_TRIGGER = "Short";
//		end;
//	Case "AS" : if Direction = "-" then TT_CYCLE_TRIGGER = "None" else TT_CYCLE_TRIGGER = "Long";
	Case "OS" : TT_CYCLE_TRIGGER = "Long";
end;


2 more that aren't being used in this ELS but are in the overall strategy

TT_SET_ARRAY - used to store list of stocks by strength

Code:
// then it builds an array of symbols, their strength value & sector
// it also stores the number of total symbols
	
inputs : SortIndicatorValue(Numeric);
vars : SymbolListCount(0), ListPosition(""), ReturnCode(0),oErrorCode(0), Sector(" ");

// has symbol already been defined in the symbol list ?
if GVGetNamedString("TTDefFlag" + getsymbolname,"N") <> "Y" then begin
   ReturnCode = GVSetNamedString("TTDefFlag" + getsymbolname,"Y");
// Get next position number 
	SymbolListCount = GVGetNamedInt("TTSymbolListCount",0);
	SymbolListCount = SymbolListCount + 1;
// Put the name of the symbol in the symbol list at the new position
	ReturnCode = GVSetString(SymbolListCount,getsymbolname);
// Store the number of symbols
	ReturnCode = GVSetNamedInt("TTSymbolListCount",SymbolListCount);
// Store the name of the sector for the symbol
	Sector = GetFundDataAsString("F_MGSEC", 1); 
	ReturnCode = GVSetNamedString("TTSector" + getsymbolname,Sector);
//print(SymbolListCount, " ",getsymbolname,", Sector = ", Sector);
end;
ReturnCode = GVSetNamedFloat("TTStrength" + getsymbolname,SortIndicatorValue);
TT_SET_ARRAY = 1;

TT_GET_ARRAY - Sort & print the list of stocks - will be used at buy time

Code:
var : LoopCount(0), Basket(0), CurrSymbol(" "), NumElements(0), ReturnCode(0);

// Set Array for sorting - I wanted to use a dynamic array but I didn't know how to do a 2dimensional 
// dynamic array

Array: RadarValues[200,2] (0);

// Set basket size
	Basket = GVGetNamedInt("TTBasket",BASKET);	
	NumElements = GVGetNamedInt("TTSymbolListCount",1);

// Loop around the symbol list - TTSymbolListCount is the list of symbols

for LoopCount = 1 to NumElements Begin
	// element 1 = strength (to 5 decimal places)
	RadarValues[LoopCount,1] = GVGetNamedFloat("TTStrength" + GVGetString(LoopCount),0);
	// element 2 = symbol number
	RadarValues[LoopCount,2] = LoopCount;
end;

// Now Sort the array by strength
// last element = -1 ascending, 1 descending
// has to be descending sort

ReturnCode = TTsortD1basedOnD2key(RadarValues, NumElements,2,1,1);

// Now print out the array 
for LoopCount = 1 to NumElements Begin
	CurrSymbol = GVGetString(RadarValues[LoopCount,2]);	
	Print("Symbol ", CurrSymbol,
		", Strength ", RadarValues[LoopCount,1],
		", Position Size ", GVGetNamedInt("TTPosSize" + CurrSymbol,1),
		", Sector ", GVGetNamedString("TTSector" + CurrSymbol," "));
end;

TT_GET_ARRAY = 1;

That'll be 20 pence.

Obviously - let's keep all this within this forum, please.
 
Here's the code guys...

Nice work Pete, well done.

Have to put nerd hat and wellies on now and delve into the detail.
Can see your modules, but not yet how they would link together. Perhaps TS8/2000 difference.
See you when I come up for air :)
Glenn
 
Nice work Pete, well done.

Have to put nerd hat and wellies on now and delve into the detail.
Can see your modules, but not yet how they would link together. Perhaps TS8/2000 difference.
See you when I come up for air :)
Glenn

OK - for the 'other side' - you'll need the following :

TT_RATE_WEAKSTRONG - indicator for radar screen - will can our strength indicator when we know what it is & store it in RelativeStrength

Code:
// This indicator calls a function which gives a strength rating
// it then calls TT_SET_ARRAY to store this strength rating in an 'array' of 
// global variables 
inputs:  MarketOpen(0930); 

Vars : ReturnCode(0),RelativeStrength(0), relstrengthcomp(0),avgrelstrcomp(0), INDUClose(0),normalizevalue(0),
	MinsSinceOpen(0); 

// Figure how many bars/mins since open so we can get an average strength for the day
MinsSinceOpen = TimetoMinutes(time) - TimetoMinutes(MarketOpen);

// As $INDU is our baseline, we should store info on that in GVs
// Store Close of Indu or get it 


if GetSymbolName = "$INDU" then begin
	ReturnCode = GVSetNamedFloat("TTInduClose",Close);
	INDUClose = Close;
end
else
	INDUClose = GVGetNamedFloat("TTInduClose",1);

// if INDUClose isn't set yet - skip this. There's no guarantee $INDU will be processed first
// ... or is there ???

if INDUClose <> 1 and MinsSinceOpen <> 0 then begin
if date <> date [1] or barnumber=1 or INDUClose[1] = 1 then
	normalizevalue = 1/(close/INDUClose); 
	relstrengthcomp = (close/INDUClose)*normalizevalue; 
	RelativeStrength = average(relstrengthcomp,MinsSinceOpen); 
//	RelativeStrength = average(relstrengthcomp,30); 

// Now call a function to put this data away for use at trade time

	ReturnCode = TT_SET_ARRAY(RelativeStrength);

//Plot the relative strength

	Plot1(RelativeStrength,"Strength");
end;

TT_POSITION_SIZE - store position size in global vars (from this forum)

Code:
// This sets Posision Size & should go on a radar screen with all symbols being analyzed
// interval setting for the position size is up to you - once set, it doesn't need to change
// in my opinion, we don't need inter-bar updates on this one

[LegacyColorValue = true]; 

{Calculates position size based upon Fixed Percentage (1% of Capital) Money Management stop-loss
Capital = X, Fixed Percentage = X/100.
Say Capital = $120,000 based on 4x margin allowed, and FIxed Percentage = 1
Money Management Stop = $120,000 *( 1/ 100) = $1200.

Use the ATR(14) in each timeframe to calculate the Position size:-
e.g.
10 minute ATR(14) = $1.00
Position Size = MM Stop / ATR = $1200 / 1.00 = 1200 shares.

******* For Day-trading or Scalping using 10 min INDU cycle, set the Data Compression of this indicator to 10 minutes.
******* For Swing Trading, set the Data Comperssion to Daily}

Inputs:
Capital(10000), {e.g. 120000 means $120,000}
FixedPercent(2), {e.g. 1 means 1 percent}
BASKET(2), {e.g. 3 means calculate position size assuming that you are taking 3 positions at once}
MaximumShares(0); {e.g. 1200 Shares.This is to ensure that non-volatile (Low ATR)stocks are not used for Scalping or Day-Trading. 
Position Size will show 0 (zero)and Magenta backgound if the calculated Size is greater than the MaxShares} 
Variables:
MMStop(0),TotalPosition(0), ReturnCode(0),PSize(0);

MMStop = (Capital * (FixedPercent/100))/(BASKET);
Psize = (MMStop / (AvgTrueRange(14)));
If Psize <= Maximumshares then begin

Plot1(Psize,"Size");
Setplotbgcolor(1,black);
TotalPosition = Last * Psize;
Plot2(TotalPosition,"Total");
End;
If Psize > MaximumShares then begin
Psize = 0;
TotalPosition = 0;
Setplotbgcolor(1,magenta);
Plot1(Psize,"Size");
Plot2(TotalPosition,"Total");
end;
Plot3(AvgTrueRange(14),"ATR");

//Store Position size & basket in global variables

ReturnCode = GVSetNamedInt("TTPosSize" + getsymbolname,IntPortion(PSize));
ReturnCode = GVsetNamedInt("TTBasket",BASKET);

TTsortD1basedOnD2Key - sorts the array used in TT_GET_ARRAY

Code:
// sorts dim1 of 2d array based on dim2 criteria
// usage is value1=sortD1basedOnD2key[myArray,90,7,1,-1] where 1 signifies element_1 of dim2 is search key

input: price[n,nn](numericArrayRef), len1(numericSimple), len2(numericSimple), key(numericSimple), HiLo(numericSimple);  // pass in 1 for Hi to Lo "SortDn", -1 for "SortUp"
var: x(0), y(0), z(0);
array: tmp[7](0);

if hilo= -1 then begin // ascending
    for x=1 to len1-1 begin 
        for y=x+1 to len1 begin
            if price[x,key]>price[y,key] then begin
                for z=1 to len2 begin
                    tmp[z]=price[x,z];  price[x,z]=price[y,z];  price[y,z]=tmp[z];
                end;
            end;
        end;
    end;
end else if hilo=1 then begin // descending
    for x=1 to len1-1 begin 
        for y=x+1 to len1 begin
            if price[x,key]<price[y,key] then begin
                for z=1 to len2 begin
                    tmp[z]=price[x,z];  price[x,z]=price[y,z];  price[y,z]=tmp[z];
                end;
            end;
        end;
    end;
end; 
TTsortD1basedOnD2key=1;

Plan is to use this info in the buy & sell algorithms once the TT_MTL_CYCLE3 throws us a signal.
 
Just a thought about Bias if I understand the spec correctly.
If you are determining the Bias in order to automatically decide which side of the market to trade, then I think there needs to be a manual override for forcing the bias.
The reason for this is that there are days when the market fundamentals change because of some important news and (e.g.) a previously strong market will become weak before the longer term indicators can respond.

Glenn

Agreed - I'll add that in soon. My original thought was that I'd probably switch this off when the market was driven by strong fundamentals.

Like today !
 
Hi, now as some of you know, my programming knowledge is, well probably at best 'junior infants level'.....of course not trying to take anything from those in junior infants who are showing promise in this area.......but, thought I would mention that in the November issue of Stocks and Commodities there is an article titled 'Corona Charts', which are apparently the next generation of superindicators.....there are 4 indicators in the Corona Chart series......

- the spectrum (from which the dominant cycle is extracted)
- the cycle signal to noise ratio
- the swing position
- the trend vigor

An interesting article, which cites John Ehler as the pioneer, and lists the site www.eminez.com where the Corona Charts are available for free and STOCKS & COMMODITIES magazine where the ELD is available for the indicators.

Just thought it might help or be useful in some way.

Frank.
 
Hi, now as some of you know, my programming knowledge is, well probably at best 'junior infants level'.....of course not trying to take anything from those in junior infants who are showing promise in this area.......but, thought I would mention that in the November issue of Stocks and Commodities there is an article titled 'Corona Charts', which are apparently the next generation of superindicators.....there are 4 indicators in the Corona Chart series......

- the spectrum (from which the dominant cycle is extracted)
- the cycle signal to noise ratio
- the swing position
- the trend vigor

An interesting article, which cites John Ehler as the pioneer, and lists the site www.eminez.com where the Corona Charts are available for free and STOCKS & COMMODITIES magazine where the ELD is available for the indicators.

Just thought it might help or be useful in some way.

Frank.

Interesting stuff. Are you volunteering to test this out for us Frank ???
 
Hi, now as some of you know, my programming knowledge is, well probably at best 'junior infants level'.....of course not trying to take anything from those in junior infants who are showing promise in this area.......but, thought I would mention that in the November issue of Stocks and Commodities there is an article titled 'Corona Charts', which are apparently the next generation of superindicators.....there are 4 indicators in the Corona Chart series......

- the spectrum (from which the dominant cycle is extracted)
- the cycle signal to noise ratio
- the swing position
- the trend vigor

An interesting article, which cites John Ehler as the pioneer, and lists the site www.eminez.com where the Corona Charts are available for free and STOCKS & COMMODITIES magazine where the ELD is available for the indicators.

Just thought it might help or be useful in some way.

Frank.

Any contribution is useful as it can open the door for new ideas. Ehlers' new work is certainly interesting. The only problem is I don't know whether TS2Ki users will be able to get these indicators to work. I would be interested in seeing the results if somebody can test them.

Naeem
 
I would be interested in seeing the results if somebody can test them.

EXACTLY !

This thread is about the development of an automated trading strategy.

[rant]
To develop an automated strategy, we need to define what the strategy is and then code it. To define the strategy we must know what works & what doesn't. To do that, some degree of testing is required of the indicators being recommended. This should be done before they are incorporated into the code.

Whilst it's fine for people to point out new indicators that are out there, this does not help us in our quest for an automated strategy. If a poster on this thread links us to articles about new indicators advertised in trading magazines, then they are effectively saying "here guys - test this yourselves".

Before we plug anything in our strategy we need to know it works, we will not know that by reading a magazine article. We will only know by testing it out. Or by peoples experience of using the indicator. We need people doing that work as well as people like myself doing the coding work.

If not, the expectation must be that people can post an indicator here that they have never used, expect me or someone else to test it, put it into the program if it works and then deliver all the code back to them to make them $$$. I don't feel this is fair.

This thread is about using proven methods to develop an automated strategy, if people want to contribute new indicators and really make a difference, then they need to test out those indicators before posting them here.

I know this may come across as me being a bit crappy - but really, if people want to contribute, then test this stuff out before asking us to look at it. Don't expect others to test it out for you, it's just an indicator try it out in real time, look how it performs & then come back to this thread with the results.
[/rant]
 
Last edited:
EXACTLY !

This thread is about the development of an automated trading strategy.

[rant]
To develop an automated strategy, we need to define what the strategy is and then code it. To define the strategy we must know what works & what doesn't. To do that, some degree of testing is required of the indicators being recommended. This should be done before they are incorporated into the code.

Whilst it's fine for people to point out new indicators that are out there, this does not help us in our quest for an automated strategy. If a poster on this thread links us to articles about new indicators advertised in trading magazines, then they are effectively saying "here guys - test this yourselves".

Before we plug anything in our strategy we need to know it works, we will not know that by reading a magazine article. We will only know by testing it out. Or by peoples experience of using the indicator. We need people doing that work as well as people like myself doing the coding work.

If not, the expectation must be that people can post an indicator here that they have never used, expect me or someone else to test it, put it into the program if it works and then deliver all the code back to them to make them $$$. I don't feel this is fair.

This thread is about using proven methods to develop an automated strategy, if people want to contribute new indicators and really make a difference, then they need to test out those indicators before posting them here.

I know this may come across as me being a bit crappy - but really, if people want to contribute, then test this stuff out before asking us to look at it. Don't expect others to test it out for you, it's just an indicator try it out in real time, look how it performs & then come back to this thread with the results.
[/rant]


Pete,

I agree with almost everything you have said. We also need to consider the fact that some people might not know what to test and I think it's important that people be given some ideas so that they can go out and test it for themselves. Hopefully, they can come back and contribute by giving us their findings.

I completely understand your rant because as a novice programmer I can truly see how much work you guys are putting in, I was about to throw my laptop out of the window last night after testing some indicator I'm working on! :LOL:

Naeem
 
Hey guys,

I took a look into Adaptive CCI, which is some of Ehler's work (earlier stuff, I think). It is CCI but instead of having a cycle length setting (like 14 or 20 as you'll find the norm on most CCI indicators) the indicator tries to evaluate and determine the cycle length, and it adapts to changing cycles.

My experience of it is that MACCI gave better signals, at least on a daily/weekly chart. I was not able to test it on intra-day data as I do not have a way to connect my TS2000i to a data server, so was testing on NinjaTrader.

I even tried to smooth the Adaptive CCI with a 5 period SMA but the MACCI still gave better signals.

Thought I'd mention this incase anyone was thinking about spending time on testing it. It probably isn't worth it.
 
Hey guys,

I took a look into Adaptive CCI, which is some of Ehler's work (earlier stuff, I think). It is CCI but instead of having a cycle length setting (like 14 or 20 as you'll find the norm on most CCI indicators) the indicator tries to evaluate and determine the cycle length, and it adapts to changing cycles.

My experience of it is that MACCI gave better signals, at least on a daily/weekly chart. I was not able to test it on intra-day data as I do not have a way to connect my TS2000i to a data server, so was testing on NinjaTrader.

I even tried to smooth the Adaptive CCI with a 5 period SMA but the MACCI still gave better signals.

Thought I'd mention this incase anyone was thinking about spending time on testing it. It probably isn't worth it.


twistedheat,

Thanks for the info that could be useful. Do you have any data that we can take a look at for the Adaptive CCI test?

Also what was your entry criteria when you were testing the Adapative CCI?

Cheers

Naeem
 
Hey guys,

I took a look into Adaptive CCI, which is some of Ehler's work (earlier stuff, I think). It is CCI but instead of having a cycle length setting (like 14 or 20 as you'll find the norm on most CCI indicators) the indicator tries to evaluate and determine the cycle length, and it adapts to changing cycles.

My experience of it is that MACCI gave better signals, at least on a daily/weekly chart. I was not able to test it on intra-day data as I do not have a way to connect my TS2000i to a data server, so was testing on NinjaTrader.

I even tried to smooth the Adaptive CCI with a 5 period SMA but the MACCI still gave better signals.

Thought I'd mention this incase anyone was thinking about spending time on testing it. It probably isn't worth it.

Thanks for the heads up !! (y)
 
I completely understand your rant because as a novice programmer I can truly see how much work you guys are putting in, I was about to throw my laptop out of the window last night after testing some indicator I'm working on! :LOL:


I've tried that - it doesn't fix the issue.
 
The question is, how does one test a number of indicators for comparative purposes?
Might sound a daft question but imo doing it properly is no trivial matter.
Also in order to spread it around, the testing has to be doable by a number of individuals with a variety of skills and experience.

Overall I think there has to be a comprehensive testing strategy and clear instructions for willing testers to follow.
Otherwise individual tests from a (begging your pardon folks) 'herd of cats' will not be comparable.

Questions raised:-
-Which indicators are to be tested ?
-What about modifications to known indicators in order to make them more adaptive ?
-Whether to use Backtesting ?
-What about the times when you wouldn't run the engine ?
-Is the indicator to be tested in one timeframe only or MTF ?
-What outputs are required to make the comparisons ?
-Which data set(s) should be used ?
-Who will co-ordinate the outputs and produce comparative results ?
-What are the criteria for determining the best one ?
-Who is qualified to answer these questions ?

More questions than answers, :rolleyes: I know, but necessary for discussion at this stage I think.

Put me down as a volunteer indicator tester.

Glenn
 
Glenn

Some good points raised.

We know that we want to use multiple time frames in our strategy but we do not need to use the same indicator on all time frames.

In terms of good information on an indicator, I'd be happy if someone played with it & presented comparisons in terms of gaving better/worse entry signals than the MACCi. That is, after all, our baseline indicator. Now - if someone can get that far, it's worth is plugging in that indicator into our strategy and testing it in parallel to the MACCi and evaluating the quality of the signals.

I ordered Ehlers 'Cybernetic Analysis' book yesterday & I'm sitting in front of it now. If I can understand more about it, I may be able to answer some more of your questions.

We all know that 90% of the financial press & financial advice is bull**** so let's go past that & do at least some kind of evaluation before recommending we try something.

Maybe we can't answer all your questions Glenn but we can encourage people to try these things themselves before posting them up as alternatives to MACCi.

Cheers

Pete
 
Top