MetaStock™ Zone Forum & FAQ Artykuły Linki Elliott Waves EasyLanguage™ Zone

A B C D E F G H I J K L M N O P R S T U V W Y Z #

Advance Issues Momentum (AIM) by Lawrence Chan and Louis Lin

Lawrence Chan and Louis Lin's article in this issue, "Boosting Profitability," includes the NeoTicker
code for their AIM indicator. The MetaStock code is listed below. This formula uses the Security Data function, which is only available in MetaStock version 8.01 or later or any version of MetaStock Professional.


Advance Issues Momentum

x:=Input("Momentum Periods",1,200,10);
(Security("ONLINE:AA", Mo(x)>0))+
(Security("ONLINE:AXP", Mo(x)>0))+
(Security("ONLINE:BA", Mo(x)>0))+
(Security("ONLINE:C", Mo(x)>0))+
(Security("ONLINE:CAT", Mo(x)>0))+
(Security("ONLINE:DD", Mo(x)>0))+
(Security("ONLINE:DIS", Mo(x)>0))+
(Security("ONLINE:EK", Mo(x)>0))+
(Security("ONLINE:GE", Mo(x)>0))+
(Security("ONLINE:GM", Mo(x)>0))+
(Security("ONLINE:HD", Mo(x)>0))+
(Security("ONLINE:HON", Mo(x)>0))+
(Security("ONLINE:HPQ", Mo(x)>0))+
(Security("ONLINE:IBM", Mo(x)>0))+
(Security("ONLINE:INTC", Mo(x)>0))+
(Security("ONLINE:IP", Mo(x)>0))+
(Security("ONLINE:JNJ", Mo(x)>0))+
(Security("ONLINE:JPM", Mo(x)>0))+
(Security("ONLINE:KO", Mo(x)>0))+
(Security("ONLINE:MCD", Mo(x)>0))+
(Security("ONLINE:MMM", Mo(x)>0))+
(Security("ONLINE:MO", Mo(x)>0))+
(Security("ONLINE:MRK", Mo(x)>0))+
(Security("ONLINE:MSFT", Mo(x)>0))+
(Security("ONLINE:PG", Mo(x)>0))+
(Security("ONLINE:SBC", Mo(x)>0))+
(Security("ONLINE:T", Mo(x)>0))+
(Security("ONLINE:UTX", Mo(x)>0))+
(Security("ONLINE:WMT", Mo(x)>0))+
(Security("ONLINE:XOM", Mo(x)>0))

 

The formula is written to use online data. It can be modified to use data stored locally by replacing the text "ONLINE:" with the path to the local data. For example, if the local data was stored in the folder C:\ MetaStock Data \ Dow 30, the second line of the formula would look like this:

(Security("C:\ MetaStock Data \ Dow 30\AA", Mo(x)>0))+

The same change would be made to all the other lines that start with the word "Security." Please note that the path entered must be correct or the formula will return errors. In addition, since custom indicators are limited to 2,500 characters, there is a limit to the number of securities this indicator can reference. This limit will vary based on the length of the path specified for the security's datafiles. Using a short path or online data will allow for more securities to be used.

--William Golson
Equis International
www.MetaStock.com

Source / From: TOP
http://www.traders.com

Equis and MetaStock® and MetaStock Professional® are registered trademarks of Equis International. Achelis Binary Wave®, The DownLoader®,
Expert Advisor®, OptionScope®, Quotecenter® and Smart Charts® are trademarks of Equis International, a Thomson Reuters company.

TradeStation® Pro, TradeStation® 2000i, OptionStation®, SuperCharts®, PowerEditor® and EasyLanguage®
are registered trademarks of TradeStation Technologies, Inc. Other names and marks referred to are the property of their respective owners.

All information provided on this website is for educational purposes only. Trading involves risk, including possible loss of principal and other losses.

Ten i inne materiały na tej stronie zostały zamieszczone zostały jedynie w celach edukacyjnych, nie ponoszę żadnej odpowiedzialno¶ci za ich stosowanie.

Gra na giełdzie i rynkach walutowych (FOREX) niesie ze sob± ryzyko poważnych strat finansowych!