Seer logo - advanced backtesting for stock, futures and forex trading systems using using technical analysis indicators, charts, money management and position sizing
SID NameDescriptionRating
559 MACDDEMAMACD like technical analysis indicator using Double Exponential Moving Average (DEMA) instead of EMANot Rated

technical analysis indicatorThe logic for this technical analysis indicator:

#MACD like technical analysis indicator using Double Exponential Moving 
#Average (DEMA) instead of EMA
my ($period1,$period2,$smooth)=@_;
#Validate the periods
ValidatePeriods($period1,$period2,$smooth);
#create the columns...
my $macdline = DEMA(Close,$period1)-DEMA(Close,$period2);
my $macds    = DEMA($macdline,$smooth);
my $macdhist = $macdline-$macds;
#rename the columns
my $name="MACDDEMA($period1,$period2,$smooth)";
SetColumnName($macdline , "$name:line");
SetColumnName($macds    , "$name:signal");
SetColumnName($macdhist , "$name:hist");
#create the indicator with the columns
return ($macdline,$macds,$macdhist);

© 2010 seer trading systems ltd
feedback FAQ legal privacy