Weekly chart (FGL)

To view extra charts click here.

Most weeks the blog will have a post called “Weekly Chart”.

The charts will be selected from the Australian ASX20 with the first chart being AMP.
Charts mostly have VSTPro templates applied with comments added.

Charts are selected in alphabetical order and for educational purposes only.
These are not recommendations to trade.

Note……………
Reading the results in the data window and comparing them to other charts can be
very useful.

Click on the link at the top of this post to view a slide show.

VST (custom ver.) "Clear method" strategy.



To view a short video on setting-up the "Clear method" click here.



This is another way to use indicators with the VST Custom Strategy.

Copy/paste the formula below in to the MetaStock “Indicator Builder”.

Name the indicator “Clear method” without the quotation marks.


{Clear swing method based on S&C article "Getting Clear With Short-Term Swings":
http://www.traders.com/Documentation/FEEDbk_docs/2010/09/Black.html
Note that the MetaStock "Clear" code as provided by Equis at www.traders.com is incorrect.

Code adapted from VSTpro original code.
http://www.metastocktools.com/vst

Coded by Jose Silva at
http://www.metastocktools.com }


{ ----------- Start of custom code ----------- }

{User inputs}
swUp:=Input("Signals: Minimum UpSwing change %",0,25,0);
swDw:=Input("Signals: Minimum DwSwing change %",0,25,0);
rev:=Input("Reverse trade signals? [1]Yes [0]No",0,1,0);
display:=Input("Display: [1]'Clear' swing line [2]Signals",1,2,2);

{Ignore inside bars, avoid up/dw same-bar clash}
insideBar:=L>Ref(L,-1) AND H<Ref(H,-1);

{Clean price direction signals}
up:=H>Ref(H,-1) AND insideBar=0;
upSignal:=up AND Alert(up=0,2);
dw:=L<Ref(L,-1) AND insideBar=0;
dwSignal:=dw AND Alert(dw=0,2);
init:=Cum(IsDefined(upSignal+dwSignal))=1;
bin:=ValueWhen(1,upSignal-dwSignal<>0 OR init,
upSignal);
up:=bin*(Alert(bin=0,2)
OR upSignal*Cum(upSignal)=1);
dw:=(bin=0)*(Cum(bin)>0)*(Alert(bin,2)
OR dwSignal*Cum(dwSignal)=1);

{Clear Long/Short signals, swing line}
ClearUp:=Cross(L,ValueWhen(1,up,Ref(H,-1)))
AND insideBar=0;
ClearDw:=Cross(ValueWhen(1,dw,Ref(L,-1)),H)
AND insideBar=0;
init:=Cum(IsDefined(ClearUp+ClearDw))=1;
bin:=
ValueWhen(1,ClearUp-ClearDw<>0 OR init,ClearUp);
Clear:=If(bin,HighestSince(1,ClearUp,L),
LowestSince(1,ClearDw,H));

{Swing signals}
entry:=Clear>Ref(Clear,-1)*(1+swUp/100);
exit:=Clear<Ref(Clear,-1)*(1-swDw/100);


{ ------------ End of custom code ------------ }

{Reverse signals choice}
entry1:=entry;
entry:=If(rev,exit,entry1);
exit:=If(rev,entry1,exit);

{Display on price chart}
If(display=1,Clear,entry-exit)

{---------------End of copy/paste-----------}


Now that the indicator has been added to the ” Indicator Quick List” open any chart and apply the “VST Custom Strategy” template.

By using the " Formula Call [fml()] " function to calculate the value of another formula the user is able to reference the "Clear method" indicator without placing the complete indicator in to the VST Custom Strategy.

Open the “VST Custom Strategy” indicator and enter the code below.

{ ------------------------------------------ }

entry:=Fml("Clear method")>0;

exit:=Fml("Clear method")<0;

entry-exit

{ ------------------------------------------ }

Close the "VST Custom Strategy" indicator and click refresh chart, now the chart will display the
"Clear method" signals.

View the video for full details.

Weekly chart (CSL)


To view extra charts click here.

Most weeks the blog will have a post called “Weekly Chart”.

The charts will be selected from the Australian ASX20.
Charts mostly have VSTPro templates applied with comments added.

Charts are selected in alphabetical order and for educational purposes only.
These are not recommendations to trade.

Note……………
Reading the results in the data window and comparing them to other charts can be
very useful.

Click on the link below the chart to view a slide show with extra charts.

*Extra VST information is available from the links below*

metastocktools.com
learnmetastock.com

Weekly chart (CBA)

To view extra charts click here.

Most weeks the blog will have a post called “Weekly Chart”.

The charts will be selected from the Australian ASX20.
Charts mostly have VSTPro templates applied with comments added.

Charts are selected in alphabetical order and for educational purposes only.
These are not recommendations to trade.

Note……………
Reading the results in the data window and comparing them to other charts can be
very useful.

Click on the link below the chart to view a slide show with extra charts.

"Clear method" tested using the VSTpro platform

To view extra charts click here,

Please refer to the stats in the commentary window on the left side of the charts.

The charts with the light grey background have the trade signals reversed from long to short.

These charts are based on a STOCKS & COMMODITIES magazine article.
"Getting Clear With Short-Term Swings":
http://www.traders.com/Documentation/FEEDbk_docs/2010/09/Black.html

The Clear method indicator used in testing these charts was created by Jose Silva
metastocktools.com
.

The first set of charts is the Australian ASX S&P 200 (XJO).

The stock charts were selected after running a VSTpro exploration and selecting the stocks with the highest Profit/Risk ratios.

The last set of charts in the slide show were created using the VSTpro Optimization template for a comparison to the Clear method.

Weekly chart (BXB)

To view extra charts click here.

Most weeks the blog will have a post called “Weekly Chart”.

The charts will be selected from the Australian ASX20.
Charts mostly have VSTPro templates applied with comments added.

Charts are selected in alphabetical order and for educational purposes only.
These are not recommendations to trade.

Note……………
Reading the results in the data window and comparing them to other charts can be
very useful.

Click on the link below the chart to view a slide show with extra charts.

Weekly chart (BHP)

To view extra charts click here


Most weeks the blog will have a post called “Weekly Chart”.

The charts will be selected from the Australian ASX20.
Charts mostly have VSTPro templates applied with comments added.

Charts are selected in alphabetical order and for educational purposes only.
These are not recommendations to trade.

Note……………
Reading the results in the data window and comparing them to other charts can be
very useful.

Click on the link below the chart to view a slide show with extra charts.

Lunar Cycle indicator for MetaStock

See previous post for charts.
This indicator is free to download from Jose Silva @ metastocktools.com
Extra infomation about the indicator is available from metastocktools.com

MetaStock -> Tools -> Indicator Builder -> New
-> copy & paste complete formula below.


============
Lunar cycles
============
---8<-----------------------------------------

{Full/New/Q1/Q3 Moon signals indicator Mk XV.

Plots:
+1 signal on Full Moon; -1 on New Moon;
+0.5 on first Quarter; -0.5 on last Quarter.
Accurate to within 2 hours every 19 years.

Signals that fall on holidays or weekends
are plotted on the next trading day.
Use the signal advance input to view
approaching signals.

Adj lunar signals to market's local Time Zone
(generally add 1hr for Daylight Saving Time):

New Zealand: +12hrs
Australia: +10
Japan: +9
SE Asia: +8
Thai/Indonesia: +7
India: +5.5
Dubai: +4
Moscow: +3
Europe: +1
UK & Portugal: 0
USA, NY: -5
Chicago: -6

http://www.travel.com.hk/region/timezone.htm

Copyright © 2001-2009 Jose Silva.
The grant of this license is for personal use
only - no resale or repackaging allowed.
All code remains the property of Jose Silva.
http://www.metastocktools.com }

{ User inputs }
TZ:=Input("Market's local Time Zone? [-12hrs to +12hrs]",-12,12,-5);
shift:=Input("Advance signal by x calendar days",-30,30,0);
plot:=Input("Plot Q1 and Q3 (half) signals? [1]Yes, [0]No",0,1,0);

{ Lunar cycle length in days (synodic month) }
LunarMonth:=29.53059;
offset:=4.86;

{ Calendar engine }
y:=Year()-(Month()<3);
leap:=Int(y/4)-Int(y/100)+Int(y/400);
mth:=Int((2+153*(Month()-3+12*(Month()<3)))/5);
dayNr:=DayOfMonth()+mth+y*365+leap-657382
-offset-TZ/24+shift;

{ New/Q1/Full/Q3 Moon cycles }
NM:=Frac((DayNr+LunarMonth/2)/LunarMonth);
Q1:=Frac((DayNr+LunarMonth/4)/LunarMonth);
FM:=Frac(DayNr/LunarMonth);
Q3:=Frac((DayNr-LunarMonth/4)/LunarMonth);

{ Lunar cycle signals }
cycle:=FM-NM;
FM:=cycle<0>0,2);
NM:=-(cycle>0 AND Alert(cycle<0,2));
cycle:=Q1-Q3;
Q1:=(cycle<0>0,2))*.5;
Q3:=(cycle>0 AND Alert(cycle<0,2))*-.5;
signals:=If(plot=1,NM+Q1+FM+Q3,NM+FM);

{ Plot Lunar signals in own window }
signals

---8<-----------------------------------------

VSTPro-"Lunar Cycle" template ASX-XJO

Lunar Cycle charts click here.

The Aussie Stock Forums has a thread "Sheer Lunacy staring at the Heavens"
http://www.aussiestockforums.com/forums/showthread.php?t=20090
The thread is about a study using the Lunar Cycle to trade, and the PDF document can be viewed here. http://xa.yimg.com/kq/groups/17324418/945690453/name/RBS%2BMoon%2BPhase.pdf/
As the VSTPro has a "Lunar Cycle" template I decided to apply the it to the ASX-XJO and found the best entry/exit was Enter=FM / Exit=NM.
The LearnMetaStock.com website also has the "Lunar Cycle" template as an extra download for the VST. LearnMetaStock.com is a subscription service with many downloads and educational video presentations.

Weekly Chart

Click here to view ANZ charts.

Most weeks the blog will have a post called “Weekly Chart”.

The charts will be selected from the Australian ASX20.
Charts mostly have VSTPro templates applied with comments added.

Charts are selected in alphabetical order and for educational purposes only.
These are not recommendations to trade.

Note……………
Reading the results in the data window and comparing them to other charts can be
very useful.

Click on the link at the top of this post to view a slide show.

Weekly Chart

Ckick here to view AMP Charts



Most weeks the blog will have a post called “Weekly Chart”.

The charts will be selected from the Australian ASX20 with the first chart being AMP.
Charts mostly have VSTPro templates applied with comments added.

Charts are selected in alphabetical order and for educational purposes only.
These are not recommendations to trade.

Note……………
Reading the results in the data window and comparing them to other charts can be
very useful.
Click on the link at the top of this post to view a slide show.

Breakout (Turtle) strategy for the VST Custom.

Click here to view video

The " Breakout " formula is at the end of this post. Copy/paste the formula into the " Custom Strategy" indicator.

The 2 charts below have been created using the VSTPro using an identical " Breakout " indicator.

Copy formula below this line............
--------------8--------------8-------------------


{VST Custom Strategy. Indicator must plot +1/-1.
Trade at own risk!
Enter your own indicator in the template below.}

x:=Input("Place your custom formula within Formula tab",0,0,0);
x:=Input("Entry/Exit output *must be* in +1/-1 format",0,0,0);


{*** Place your code below ***}

{ User inputs }
pds1:=21; {Enter Long breakout periods}

pds2:=10; {Enter Exit Long breakout periods}

{Best not to edit below this line
-----8-------------8---------------8}
x:=4; {"use Open=1 High=2 Low=3 Close=4 Volume=5 WC=6"}
;
delay:=0; {Input("Entry and Exit delay"}

plot:=1; {Input("Signals: [1]Clean, [2]All, [3]Trade binary"}

{ Select breakout price field }
x:=If(x=1,O,If(x=2,H,If(x=3,L,If(x=5,V,If(x=6,WC(),C)))));

{ Entry/Exit Long breakouts }
entry:=x>Ref(HHV(x,pds1),-1);
exit:=x0 OR init,long);
long:=flag*(Alert(flag=0,2) OR init);
short:=(flag=0)*(Alert(flag,2) OR init);
signals:=long-short;

{ Plot in own window }
Ref(If(plot=2,entry,0),-delay);
Ref(If(plot=1,signals,
If(plot=2,-exit,flag)),-delay)

Updated code for the % Stop

Below is updated code sent from Jose Silva @ metastocktools.com

As for the stop code, the formula below plots identically and faster (for explorations) with two of the seven PREV functions taken out:

---8<---------------------------------- perc:=Input("Trailing Loss %",0,100,14); loss:=C*perc/100; trail:= If(LLV(C,2)>PREV,Max(PREV,C-loss),
If(HHV(C,2)PREV,C-loss,C+loss)));

entry:=Cross(C,trail);
exit:=Cross(trail,C);
entry-exit

---8<---------------------------------- This formula is even faster with three PREV functions taken out: ---8<---------------------------------- {Input} perc:=Input("Trailing Loss %",0,100,14); {Stops} loss:=C*perc/100; stopLong:=If(CPREV,C+loss,Min(C+loss,PREV));

{Signals}
In:=Cross(C,Ref(stopShort,-1));
Out:=Cross(Ref(stopLong,-1),C);
Init:=Cum(In+Out>-1)=1;
InInit:=Cum(In)=1;
flag:=BarsSince(Init OR In)
< BarsSince(Init OR Out)+InInit;
signals:=(InInit AND Alert(InInit=0,2)
OR flag AND Alert(flag=0,2))
-(flag=0 AND Alert(flag,2));

{Display}
signals
---8<----------------------------------

VSTPro charts .






Testing a % stop-go indicator with the VST Custom Strategy.





Recently I noticed a bookmarked web page, http://stocata.org/metastock/stop_trail_perc.html and decided to test the formula with the VST Custom Strategy. The website has several other MetaStock formula that could be tested with the VST.

As with many indicators they work fine when the chart is trending nicely up or down but perform poorly on choppy or sideways movement.

I needed to use this indicator with the VST and it will not plot +1/-1 so I used the Cross function in MetaStock to create the +1/-1 plot.

Copy and paste the % Stop indicator below into MetaStock using the Indicator Builder.

8888888888888888888888888888888888888888888888888888888888888888
{% Auto stop-go}

perc:=Input("Trailing Loss % :",0,100,14);
loss:=C*perc/100;
trail:=
If(C>PREV AND Ref(C,-1)>PREV,
Max(PREV,C-loss),
If(CPREV,C-loss,C+loss)));
Trail
8888888888888888888888888888888888888888888888888888888888888888

Name the Indicator “ % Auto stop-go “
Plot the “ % Auto stop-go “ indicator in the chart window.

Copy/paste the code below into the “ VST Custom Strategy “ indicator.

8888888888888888888888888888888888888888888888888888888888888
{VST Custom Strategy}

{VST Custom formula entry/exit instructions.
Trade at own risk!
Enter your own formula in the template below.
The formula must plot a +1/-1 on any chart.
Entry/exit formula must end with a semicolon [;] }

entry:= {<- Do not change entry parameter name} {-------Place your entry formula below this line------} Cross(CLOSE,Fml("% Auto stop-go")); exit:= {<- Do not change exit parameter name} {-------Place your exit formula below this line-------} Cross(Fml("% Auto stop-go"),CLOSE); {-------Do not edid below this line------} entry-exit {<- Do not change } 88888888888888888888888888888888888888888888888888888888888 Always REFRESH the chart after any changes. I have purchased the VSTPro so I can now post both the VST Custom and Pro charts.

VST Custom entry/exit signal testing..




The VST Custom indicator requires the input to be +1/-1.

A MetaStock user may be unsure about the way a formula or indicator will plot and an easy way to test for the +1/-1 plot is to enter the code into a simple indicator and plot on any open chart.

If the user has several formula to test an easy system is to have your code for testing entered into Windows Notepad. Copy/paste from Notepad to MetaStock.

Using one of the indicators on this post enter it into MetaStock using the Indicator Builder.
Copy/paste from this post and name it [ VST Custom-01-entry/exit indicator tester ]

Open the "VST Custom-01-entry/exit indicator tester" on any chart and then....
Right click on the indicator within the window to highlight it then left click. This will open up the properties window.

Click on the formula tab to display the formula and paste the next formula to test over the top of the original code.

Click OK at the bottom of the window and the new formula will now be displayed in the window.

Repeat the steps above, as required, until all formula are tested.


********************************************************************


{VST Custom formula entry/exit or indicator +1/-1 tester.
Trade at own risk!
Enter your own formula or indicator in the template below.}

x:=Input("Place your custom formula within Formula tab",0,0,0);
x:=Input("Entry/Exit output *must be* in +1/-1 format",0,0,0);


{*** Place your code below ***}


pds1:=21; {HHV (long) breakout periods}
pds2:=10; {LLV (short) breakout periods}
x:=4; {use Open=1 High=2 Low=3 Close=4 Vol=5}

x:=If(x=1,O,If(x=2,H,If(x=3,L,If(x=5,V,C))));
entry:=x>Ref(HHV(x,pds1),-1);
exit:=x Mov(C,40,E) AND HHVBars(H,70)=0;





***********************************************************************
The indicator below can be used as a temlpate to enter separate entry/exit formula.
The formula entered is for demonstration only.
***********************************************************************


{VST Custom formula entry/exit instructions.
Trade at own risk!
Enter your own formula in the template below.
The formula must plot a [1] on any chart.
Entry/exit formula must end with a semicolon [;] }

x:=Input("Place your custom formula within Formula tab",0,0,0);
x:=Input("Entry/Exit output *must be* in +1/-1 format",0,0,0);

entry:= {<- Do not change entry parameter name}
{--------------Place your entry formula below this line------------}

BarsSince(Cross(2,RSI(2))=1)=6;

exit:= {<- Do not change exit parameter name}
{--------------Place your exit formula below this line-------------}

Cross(Ref(Mov(L,180,E),-1),C);

entry-exit {<- Do not change }

VST (custom ver.) changing to the "VST" ATR band strategy



Place the VST template on any chart, open the "VST Special Properties" window by clicking the ATR bands, change the inputs - close - REFRESH chart to see the results in a visual display.

Always REFRESH the chart after making any changes.

VST Custom "Milk Money Trade" strategy charts S&P500


Placing the "Milk Money Trade" code into MetaStock.

The blue text on the chart explains how to place the code into the Indicator Editor.

If for some reason a problem occurs with the VST Custom Indicator or Template just re-install.

VST (custom ver.) "Milk Money Trade" strategy test

This post contains the MetaStock code for the "Milk Money Trade" strategy.

The "VSTPro" test results are towards the end of the post.

The next post will display charts with added text on using the VST (custom ver.) template to chart the Milk Money Trade stratey.


{Milk Money Trade strategy.

http://www.thinkmoney-digital.com/thinkmoney/2010springred#pg30

Coded by Jose Silva at
http://www.metastocktools.com }

{User Inputs}
pds1:=Input("EMA periods",1,260,20);
shift:=Input("EMA Envelope shift %",0,20,4);
pds2:=Input("Awesome Oscillator pds1",1,260,5);
pds3:=Input("Awesome Oscillator pds2",2,260,21);
plot:=Input("[1]Long [2]Short [3]MAE [4]Awesome Osc",1,4,1);

{EMA}
EMA:=Mov(C,pds1,E);

{MAE bands}
upper:=EMA*(1+shift/100);
lower:=EMA*(1-shift/100);

{Awesome Oscillator}
AO:=Mov(MP(),pds2,S)-Mov(MP(),pds3,S);
up:=AO>Ref(AO,-1);
dw:=AO0 OR init,entry);

{Signals Long}
entry:=up*setup;
init:=Cum(IsDefined(entry+exit))=1;
bin:=ValueWhen(1,entry-exit<>0 OR init,entry);
entry:=bin
*(Alert(bin=0,2) OR entry*Cum(entry)=1);
exit:=(bin=0)*(Cum(bin)>0)*Alert(bin,2);
long:=entry-exit;

{Setup Short}
entry:=Cross(H,upper);
exit:=Cross(EMA,L);
init:=Cum(IsDefined(entry+exit))=1;
setup:=ValueWhen(1,entry-exit<>0 OR init,entry);

{Signals Short}
entry:=dw*setup;
init:=Cum(IsDefined(entry+exit))=1;
bin:=ValueWhen(1,entry-exit<>0 OR init,entry);
entry:=bin
*(Alert(bin=0,2) OR entry*Cum(entry)=1);
exit:=(bin=0)*(Cum(bin)>0)*Alert(bin,2);
short:=entry-exit;

{Display}
If(plot=3,upper,0);
If(plot=3,EMA,If(plot=4,AO*up,0));
If(plot=1,long,If(plot=2,short,
If(plot=3,lower,AO*dw)))

---8<----------------------------------------


Backtest results using the VSTpro:

----------------------------------------------------------

Milk Money Trade Long - S&P500 stocks, 12 years' EOD data

P/Rratio 0.5
Tprofit% 23.55
MaxRisk% 53.75
Win% 62.5
Leverage 0.6
PosSize% 55.85
W/Lratio 0.8
Avg Prds 10.3
T trade% 18.45
Tprofit% 7.3
T loss% 11.25


Milk Money Trade Short - S&P500 stocks, 12 years' EOD data

P/Rratio 0
Tprofit% -15.85
MaxRisk% 62.4
Win% 58.3
Leverage 0.5
PosSize% 48.1
W/Lratio 0.6
Avg Prds 10.7
T trade% 23
Tprofit% 7.7
T loss% 15.1

----------------------------------------------------------

Visual Strategy Trader (VST) - v1.0 (custom version)

Visual Strategy Trader (VST) - v1.0 (custom version)
===========================

This add-on requires the VST platform to be already installed on MetaStock v8.0 or above. VST is free and is only available from:Download here


Please note that past performance is no guarantee of future results. Trade at your own risk!


Setup
-----

Before installing this custom version of the VST, please make sure that MetaStock is closed.

Download Visual Strategy Trader (VST) - v1.0 (custom version) here

This will install the following into MetaStock v8.0 or higher versions:


2 Indicators:
"VST Custom Strategy" - place your custom strategy code within this indicator
"VST Special" - Bands and signals based on 30 strategy combinations

1 Template:
"VST Custom Strategy.mwt" - VST custom chart Template.


Usage
-----
After installing the above, open any chart and apply the "VST Custom Strategy.mwt" chart template.
Place your custom strategy code within the "VST Custom Strategy" indicator for an instant Profit/Risk backtest on that chart.

Please make sure that the Expert Commentary window is open and docked: MetaStock -> View -> Expert Commentary.
Click on the chart bands to access the original VST indicator user input global parameters, and refresh chart after any changes.
Click on the VST Profit long to access the profit/risk global parameters, and refresh chart after any changes.

The Expert Commentary window displays current settings.
Always refresh chart after any changes in any parameters. This will also immediately change Expert signals and commentary, as well as the profit and risk indicator outputs.

My first test with the VST

I downloaded the free VST in early June, and after about 6 weeks of viewing charts using the ATR band entry/exit template, I decided to subscribe to LearnMetaStock web site. I down loaded the VST-LMS version which would allow the entry of my own entry/exit formula.

Being able to use your own criteria for entry/exit signals opened up the VST, and I am now able to test a vast range of indicators and instantly view the results.

Some of the test results were surprisingly bad.

After double checking the VST results manually with a pen, paper and calculator the VST was spot-on. I then looked at the chart’s buy/exit signals a little closer, and found some charts had one to several, large losing trades. (Would the trader have taken these losing trades? Looking at some of the charts and the price action at the time the trade was taken, I think not.)

Some systems require discretion by the user, and are not 100% mechanical. I viewed a video presentation at the LearnMetaStock web site on how to trade with the RMO, and it explains how to use your own discretion when taking the buy/sell signals-very helpful.

I will post charts to this blog as I test different strategies.

The starting point.

PremiumData
I am using PremiumData to supply data in MetaStock format.

Official MetaStock forum
Assists with problems and formula. Please use the forum search facility first, as you may find your question has been asked previously.

MetaStock
Equis web site, the main hub for MetaStock information.

MetaStockTools.com
Web site of Jose Silva, creator of the “Visual Strategy Trader”. The site content includes MetaStock formula, charts, useful links and comprehensive information about the VST.

LearnMetaStock
Excellent MetaStock training with extra VST download and additional video instructions, subscription required.

ASX ETFS GOLD - 7 year/12 month charts


Left click chart to expand.

This VST template is using the default ATR Band parameters. (6/1)

The leverage in the "VST Profit Long" indicator has been changed from (1) to (3)

Leverage increases profits and also RISK
 
Design Credit Best Blogger Tips | Best Blogger Templates | Best Social Icons