Wolf Wave

Studies that have been contributed to the community by other users. If you’ve got something useful to share, that’s great!
scalp2000
Posts: 13
Joined: 16 Jan 2010

Wolf Wave

Postby scalp2000 » 19 Jan 2010

I plot this indicator and it doesn't work.
Can you help me?

P.S. It works on TS...
reference: http://www.traderslaboratory.com/forums ... -2686.html

Code: Select all

[LegacyColorValue = true];

{======================== ===============HEADER==== ===================

Study based on Connors & Raschke's "Wolfe Waves"

========================= ========= DECLARATIONS =======================}

INPUTS:
TICKCHG(0), {Change (number of ticks) required to set up a new swing high/low.}
PCTCHG(.2), {Percent change in price to set up a new swing high/low}
OCCUR(1),
PLOTBARS(20),
ETALINE(TRUE),
ZIGZAG(TRUE);


ARRAY:
PBAR[50](0),
P[50](0);

VARS:
X(0),
PP(1),
JA_SLOPE1(0),
JLA_CTR(0),
JLA_LINE(0),
JAIRHBAR(0), { LAST SWING HIGH BAR}
JAIRLBAR(0), {LAST SWING LOW BAR}
LOWSEEK(FALSE), {LOOKING FOR A LOW OR A HIGH?}
W(0), {COUNTER}
JLA_IRH(0), {LAST SWING HIGH VALUE}
JLA_IRL(99999), {LAST SWING LOW VALUE}
JA_SLOPE2(0),
JA_SLOPE3(0),
JLA_PT1(0),
WOLFE(0);


{==================MAIN PROGRAM================== =======}

IF CURRENTBAR = 1 THEN P[50] = C;

IF LOWSEEK = FALSE AND P[50] <= H THEN
BEGIN
P[50] = H;
PBAR[50] = 0;
END;


IF LOWSEEK = TRUE AND P[50] >= L THEN
BEGIN
P[50] = L;
PBAR[50] = 0;
END;

IF (LOWSEEK = FALSE AND PBAR[50] <> 0) THEN
BEGIN
IF (TICKCHG = 0
AND L < P[50] * ( 1 - PCTCHG / 100) )
OR (TICKCHG <> 0
AND L < ( P[50] - tickchg * minmove points)) THEN
BEGIN
IF ZIGZAG = TRUE THEN PLOT4[PBAR[50]](P[50],"SWINGS");

LOWSEEK = TRUE;

FOR W = 1 TO 49
BEGIN
PBAR[W] = PBAR[W+1];
P[W] = P[W+1];
END;

P[50] = L;
PBAR[50] = 0;
END;
END;

IF (LOWSEEK = TRUE AND PBAR[50] <> 0) THEN
BEGIN
IF (TICKCHG = 0
AND H> P[50] * ( 1 + PCTCHG / 100))
OR (TICKCHG <> 0
AND H > (P[50] + tickchg * minmove points )) THEN
BEGIN
IF ZIGZAG = TRUE THEN PLOT4[PBAR[50]](P[50],"SWINGS");
LOWSEEK = FALSE;

FOR W = 1 TO 49
BEGIN
PBAR[W] = PBAR[W+1];
P[W] = P[W+1];
END;

P[50] = H;
PBAR[50] = 0;
END;
END;


IF TIME = LASTCALCTIME
AND DATE = LASTCALCDATE
AND P[48 - PP] <> 0 THEN
BEGIN
PP = -1;
WOLFE = 0;

WHILE WOLFE < OCCUR AND PP < 46
BEGIN
PP = PP + 1;
VALUE1 = P[47-PP];
VALUE2 = P[48-PP];
VALUE3 = P[49-PP];
VALUE4 = P[50-PP];

CONDITION1 =
VALUE2 > VALUE1
AND VALUE4 > VALUE3
AND VALUE4 < VALUE2
AND VALUE3 < VALUE1
AND VALUE4 > VALUE1;

CONDITION2 =
VALUE2 < VALUE1
AND VALUE4 < VALUE3
AND VALUE4 > VALUE2
AND VALUE3 > VALUE1
AND VALUE4 < VALUE1;

IF CONDITION1 OR CONDITION2 THEN WOLFE = WOLFE + 1;

END;

JA_SLOPE1 = (P[49-PP] - P[47-PP]) / (PBAR[47-PP] - PBAR[49-PP]);
JA_SLOPE2 = (P[50-PP] - P[47-PP]) / (PBAR[47-PP] - PBAR[50-PP]);


{LINE 1-3}
VALUE90 = TL_New(DATE[PBAR[47-PP]],TIME[PBAR[47-PP]],P[47-PP],
DATE[PBAR[49-PP]], TIME[PBAR[49-PP]],P[49-PP]);
Value14=TL_SetColor(VALUE90, 5);
{VALUE93 = TL_SetExtRight(VALUE90,TR UE);}
VALUE94 = TL_SETEND(VALUE90,DATE[PBAR[49-PP]-PLOTBARS],
TIME[PBAR[49-PP]-PLOTBARS],
TL_GETVALUE(VALUE90,
DATE[PBAR[49-PP]-PLOTBARS],
TIME[PBAR[49-PP]-PLOTBARS]));

{LINE 1-4}
VALUE91 = TL_NEW(DATE[PBAR[47-PP]],TIME[PBAR[47-PP]],P[47-PP],
DATE[PBAR[50-PP]], TIME[PBAR[50-PP]],P[50-PP]);
Value14=TL_SetColor(VALUE91, 16);
TL_SETEND(VALUE91,DATE[PBAR[49-PP]-PLOTBARS],
TIME[PBAR[49-PP]-PLOTBARS],TL_GETVALUE(VALUE91,
DATE[PBAR[49-PP]-PLOTBARS],TIME[PBAR[49-PP]-PLOTBARS]));

{ETA LINE}

IF ETALINE THEN
BEGIN
VALUE92 = TL_NEW(DATE[PBAR[48-PP]],TIME[PBAR[48-PP]],P[48-PP],
DATE[PBAR[50-PP]], TIME[PBAR[50-PP]],P[50-PP]);
Value14=TL_SetColor(VALUE92, 4);
TL_SETEND(VALUE92,DATE[PBAR[50-PP]-PLOTBARS],
TIME[PBAR[50-PP]-PLOTBARS],TL_GETVALUE(VALUE92,
DATE[PBAR[50-PP]-PLOTBARS],TIME[PBAR[50-PP]-PLOTBARS]));
END;
END;

IF DATE = LASTCALCDATE
AND TIME = LASTCALCTIME
AND ZIGZAG = TRUE THEN
BEGIN
JA_SLOPE3 = (P[50] - P[49]) / (PBAR[49] - PBAR[50]);

FOR JLA_CTR = PBAR[49] DOWNTO PBAR[50]
BEGIN
PLOT4[JLA_CTR](P[49] + (PBAR[49] - JLA_CTR) * JA_SLOPE3,"Swings");
END;
END;

FOR W = 1 TO 50
BEGIN
PBAR[W] = PBAR[W]+1;
END;

tcat
Posts: 175
Joined: 02 Feb 2008
Location: Lausanne, Switzerland
Has thanked: 9 times
Been thanked: 5 times

Postby tcat » 19 Jan 2010

I have successfully compiled and plotted the code you provided on USDJPY (or JPYA0 to be accurate) - 15 min timeframe.

I do however get an error on the 4 hours timeframe "Trying to access at data to future: Bars reference value: -18"
I'm not familiar with this error message.

scalp2000
Posts: 13
Joined: 16 Jan 2010

Postby scalp2000 » 20 Jan 2010

I have the same problem!!
Why?

SUPER
Posts: 646
Joined: 03 Mar 2007
Has thanked: 106 times
Been thanked: 84 times

Postby SUPER » 20 Jan 2010

Play around with your input values and see if it makes any difference

bowlesj3
Posts: 2180
Joined: 21 Jul 2007
Has thanked: 227 times
Been thanked: 429 times

Postby bowlesj3 » 20 Jan 2010

Are there any pictures of what this wave looks like? Several if possible.

User avatar
Andrew Kirillov
Posts: 1589
Joined: 28 Jul 2005
Has thanked: 2 times
Been thanked: 31 times
Contact:

Postby Andrew Kirillov » 20 Jan 2010

The code was wrong. It tried to reference "-19" bars back. I don't know why TS ignores it.
Here is the fixed code:


Code: Select all

[LegacyColorValue = true];

{======================== ===============HEADER==== ===================

Study based on Connors & Raschke's "Wolfe Waves"

========================= ========= DECLARATIONS =======================}

INPUTS:
TICKCHG(0), {Change (number of ticks) required to set up a new swing high/low.}
PCTCHG(.2), {Percent change in price to set up a new swing high/low}
OCCUR(1),
PLOTBARS(20),
ETALINE(TRUE),
ZIGZAG(TRUE);


ARRAY:
PBAR[50](0),
P[50](0);

VARS:
X(0),
PP(1),
JA_SLOPE1(0),
JLA_CTR(0),
JLA_LINE(0),
JAIRHBAR(0), { LAST SWING HIGH BAR}
JAIRLBAR(0), {LAST SWING LOW BAR}
LOWSEEK(FALSE), {LOOKING FOR A LOW OR A HIGH?}
W(0), {COUNTER}
JLA_IRH(0), {LAST SWING HIGH VALUE}
JLA_IRL(99999), {LAST SWING LOW VALUE}
JA_SLOPE2(0),
JA_SLOPE3(0),
JLA_PT1(0),
WOLFE(0);

var: _offset(0);

{==================MAIN PROGRAM================== =======}

IF CURRENTBAR = 1 THEN P[50] = C;

IF LOWSEEK = FALSE AND P[50] <= H THEN
BEGIN
P[50] = H;
PBAR[50] = 0;
END;


IF LOWSEEK = TRUE AND P[50] >= L THEN
BEGIN
P[50] = L;
PBAR[50] = 0;
END;

IF (LOWSEEK = FALSE AND PBAR[50] <> 0) THEN
BEGIN
IF (TICKCHG = 0
AND L < P[50] * ( 1 - PCTCHG / 100) )
OR (TICKCHG <> 0
AND L < ( P[50] - tickchg * minmove points)) THEN
BEGIN
IF ZIGZAG = TRUE THEN PLOT4[PBAR[50]](P[50],"SWINGS");

LOWSEEK = TRUE;

FOR W = 1 TO 49
BEGIN
PBAR[W] = PBAR[W+1];
P[W] = P[W+1];
END;

P[50] = L;
PBAR[50] = 0;
END;
END;

IF (LOWSEEK = TRUE AND PBAR[50] <> 0) THEN
BEGIN
IF (TICKCHG = 0
AND H> P[50] * ( 1 + PCTCHG / 100))
OR (TICKCHG <> 0
AND H > (P[50] + tickchg * minmove points )) THEN
BEGIN
IF ZIGZAG = TRUE THEN PLOT4[PBAR[50]](P[50],"SWINGS");
LOWSEEK = FALSE;

FOR W = 1 TO 49
BEGIN
PBAR[W] = PBAR[W+1];
P[W] = P[W+1];
END;

P[50] = H;
PBAR[50] = 0;
END;
END;


IF TIME = LASTCALCTIME
AND DATE = LASTCALCDATE
AND P[48 - PP] <> 0 THEN
BEGIN
PP = -1;
WOLFE = 0;
WHILE WOLFE < OCCUR AND PP < 46
BEGIN
PP = PP + 1;
VALUE1 = P[47-PP];
VALUE2 = P[48-PP];
VALUE3 = P[49-PP];
VALUE4 = P[50-PP];

CONDITION1 =
VALUE2 > VALUE1
AND VALUE4 > VALUE3
AND VALUE4 < VALUE2
AND VALUE3 < VALUE1
AND VALUE4 > VALUE1;

CONDITION2 =
VALUE2 < VALUE1
AND VALUE4 < VALUE3
AND VALUE4 > VALUE2
AND VALUE3 > VALUE1
AND VALUE4 < VALUE1;

IF CONDITION1 OR CONDITION2 THEN WOLFE = WOLFE + 1;
END;


if ( PBAR[47-PP] - PBAR[49-PP] = 0 ) then JA_SLOPE1 = 0 else
JA_SLOPE1 = (P[49-PP] - P[47-PP]) / (PBAR[47-PP] - PBAR[49-PP]);
if ( PBAR[47-PP] - PBAR[50-PP] = 0 ) then JA_SLOPE2 = 0 else
JA_SLOPE2 = (P[50-PP] - P[47-PP]) / (PBAR[47-PP] - PBAR[50-PP]);


{LINE 1-3}
VALUE90 = TL_New(DATE[PBAR[47-PP]],TIME[PBAR[47-PP]],P[47-PP],
DATE[PBAR[49-PP]], TIME[PBAR[49-PP]],P[49-PP]);
Value14=TL_SetColor(VALUE90, 5);
{VALUE93 = TL_SetExtRight(VALUE90,TR UE);}
_offset = iff(PBAR[49-PP]-PLOTBARS < 0 , 0, PBAR[49-PP]-PLOTBARS);
VALUE94 = TL_SETEND(VALUE90,DATE[_offset],TIME[_offset],TL_GETVALUE(VALUE90,DATE[_offset],TIME[_offset]));

{LINE 1-4}
VALUE91 = TL_NEW(DATE[PBAR[47-PP]],TIME[PBAR[47-PP]],P[47-PP],
DATE[PBAR[50-PP]], TIME[PBAR[50-PP]],P[50-PP]);
Value14=TL_SetColor(VALUE91, 16);
_offset = iff(PBAR[49-PP]-PLOTBARS < 0 , 0, PBAR[49-PP]-PLOTBARS);
TL_SETEND(VALUE91,DATE[_offset],TIME[_offset],TL_GETVALUE(VALUE91,DATE[_offset],TIME[_offset]));

{ETA LINE}

IF ETALINE THEN
BEGIN
VALUE92 = TL_NEW(DATE[PBAR[48-PP]],TIME[PBAR[48-PP]],P[48-PP],
DATE[PBAR[50-PP]], TIME[PBAR[50-PP]],P[50-PP]);
Value14=TL_SetColor(VALUE92, 4);
_offset = iff(PBAR[50-PP]-PLOTBARS < 0 , 0, PBAR[50-PP]-PLOTBARS);
TL_SETEND(VALUE92,DATE[_offset],TIME[_offset],TL_GETVALUE(VALUE92,DATE[_offset],TIME[_offset]));

END;
END;

IF DATE = LASTCALCDATE
AND TIME = LASTCALCTIME
AND ZIGZAG = TRUE THEN
BEGIN
if ( PBAR[49-PP] - PBAR[50-PP] = 0 ) then JA_SLOPE3 = 0 else
JA_SLOPE3 = (P[50] - P[49]) / (PBAR[49] - PBAR[50]);
FOR JLA_CTR = PBAR[49] DOWNTO PBAR[50]
BEGIN
PLOT4[JLA_CTR](P[49] + (PBAR[49] - JLA_CTR) * JA_SLOPE3,"Swings");
END;
END;

FOR W = 1 TO 50
BEGIN
PBAR[W] = PBAR[W]+1;
END;

khalaad
Posts: 323
Joined: 07 Jan 2007
Location: Lahore, Pakistan
Has thanked: 64 times
Been thanked: 57 times

Re: Wolf Wave

Postby khalaad » 11 Sep 2010

BEWARE!

Whatever the code plots, it does NOT plot WolfeWave!!

WolfeWave is sublime!

This is rather INELIGANT!!

User avatar
TJ
Posts: 7740
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2221 times

Re: Wolf Wave

Postby TJ » 11 Sep 2010

BEWARE!

Whatever the code plots, it does NOT plot WolfeWave!!

WolfeWave is sublime!

This is rather INELIGANT!!
can you elaborate a bit more on your observation?

khalaad
Posts: 323
Joined: 07 Jan 2007
Location: Lahore, Pakistan
Has thanked: 64 times
Been thanked: 57 times

Re: Wolf Wave

Postby khalaad » 11 Sep 2010

Most certainly.

Inserted on the attached eminiS&P500 chart, the code produced an illustration violating more than one WolfeWave rules.

For rules, it is best to refer to the discoverer of WolfeWave, Bill Wolfe; attached are the basic RULES from http://www.wolfewave.com
eminiS&P500.png
(50.25 KiB) Downloaded 3071 times
Attachments
Bullish WolfeWave RULES.pdf
(112.71 KiB) Downloaded 736 times

khalaad
Posts: 323
Joined: 07 Jan 2007
Location: Lahore, Pakistan
Has thanked: 64 times
Been thanked: 57 times

Re: Wolf Wave

Postby khalaad » 11 Sep 2010

However, attached is what may be a WolfeWave.

I say "may be" because the example is NOT a good one; I just thought I should stay with the same chart.

Khalid
Attachments
This MAY be a WolfeWave..png
(49.8 KiB) Downloaded 3004 times

khalaad
Posts: 323
Joined: 07 Jan 2007
Location: Lahore, Pakistan
Has thanked: 64 times
Been thanked: 57 times

Re: Wolf Wave

Postby khalaad » 13 Sep 2010

Even when a WolfeWave is WEAK it is quite often awesome!

The eminiS&P500 updated.

Khalid

PS -- When it is STRONG, it is quite simply sublime (for the future).
Attachments
eminiS&P500_update.png
(49.39 KiB) Downloaded 2939 times

Tresor
Posts: 1104
Joined: 29 Mar 2008
Has thanked: 12 times
Been thanked: 53 times

Re: Wolf Wave

Postby Tresor » 03 Jan 2011

Only for the purpose of project management (feature request) - doc. files are not allowed.
Attachments
CLONNING A TRENDLINE IN ITS FOOTPRINT.doc
(436 KiB) Downloaded 682 times

Tresor
Posts: 1104
Joined: 29 Mar 2008
Has thanked: 12 times
Been thanked: 53 times

Re: Wolf Wave

Postby Tresor » 03 Jan 2011

There are three feature requests that wolfe traders can find useful and worth voting for:
(i) trendline magnet: https://www.multicharts.com/pm/viewissu ... e_no=MC-70
(ii) clonning trendline in its footprint*: https://www.multicharts.com/pm/viewissu ... e_no=MC-97
(iii) multiple command buttons for drawing tools (trendlines inclusive): https://www.multicharts.com/pm/viewissu ... e_no=MC-58

* you may find a nice wolfe picture in the link provided to this feature request.

bomberone1
Posts: 310
Joined: 02 Nov 2010
Has thanked: 26 times
Been thanked: 23 times

Re: Wolf Wave

Postby bomberone1 » 22 Apr 2013

Could you post the right version of Wolf Wave please?

khalaad
Posts: 323
Joined: 07 Jan 2007
Location: Lahore, Pakistan
Has thanked: 64 times
Been thanked: 57 times

Re: Wolf Wave

Postby khalaad » 23 Apr 2013

Could you post the right version of Wolf Wave please?
To the best of my knowledge, a true WolfeWave indocator does not exist; at least not publically for MultiCharts.

Go to the WolfeWave Website, and download Seeing the Future. Study it, train your eye. You most probably won't need an indicator.

Khalid


Return to “User Contributed Studies and Indicator Library”