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 #

Linear Regression Slope - Normalized
"Normalized" Linear Regression Slope * To: metastock@xxxxxxxxxxxxx
* Subject: "Normalized" Linear Regression Slope
* From: Ron <ronber@xxxxxxxxxxxxx>
* Date: Sat, 25 May 2002 08:49:56 -0400
* References: <LNBBKIIKPJFAFHFNIBKOKEPLFCAA.neo1@xxxxxxxxx>
* Reply-To: metastock@xxxxxxxxxxxxx
* Sender: owner-metastock@xxxxxxxxxxxxx
* User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:0.9.2) Gecko/20010726 Netscape6/6.1

Hi folks -

I'm using the following code trying to get the slope of the % change in price (close).

I'm using:


Linear Regression Slope - Normalized

Period:=Input("Periods",3,200,10);
ZeroKiller:=If(C=Ref(C,-1),0,C/(C-Ref(C,-1)));
NormalSlope:=LinRegSlope(ZeroKiller,Period);
NormalSlope;
0;

 

I think I want this or else a change of $1 for a $10 stock and a $100 stock would be the same. Is that correct?
I'm using ZeroKiller to get rid of the div by 0 error message that shows up. (Although the plot still is drawn)
I'd appreciate any help y'all have to offer. TIA

Ron
Source / From: TOP
http://purebytes.com/archives/metastock/

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!