App-Chart

 view release on metacpan or  search on metacpan

lib/App/Chart/doc/chart.html  view on Meta::CPAN

</p>

<hr>
</div>
<div class="section-level-extent" id="MASS-Index">
<div class="nav-panel">
<p>
Next: <a href="#Momentum-and-Rate-of-Change" accesskey="n" rel="next">Momentum</a>, Previous: <a href="#MACD" accesskey="p" rel="prev">MACD</a>, Up: <a href="#Indicators" accesskey="u" rel="up">Indicators</a> &nbsp; [<a href="#Concept-Index" title="I...
</div>
<h3 class="section" id="MASS-Index-1"><span>10.22 MASS Index<a class="copiable-link" href="#MASS-Index-1"> &para;</a></span></h3>
<a class="index-entry-id" id="index-MASS-index"></a>
<a class="index-entry-id" id="index-Index_002c-MASS"></a>

<a class="index-entry-id" id="index-Dorsey_002c-Donald"></a>
<p>The MASS index by Donald Dorsey is based on daily trading range.  Each day&rsquo;s
range high to low is calculated and those values are smoothed with a 9-day EMA
(see <a class="pxref" href="#Exponential-Moving-Average">Exponential Moving Average</a>).  A ratio of that value with a second EMA
smoothing is then taken, and the past 25 days of those ratios added up.
</p>
<div class="example">
<pre class="example-preformatted">                    EMA[9] of high-low
MASS = Sum[25] of -----------------------
                  EMAofEMA[9] of high-low
</pre></div>

<p>The EMA and the EMA of EMA are normally quite close, making their ratio
usually about 1 and hence the sum formed is usually close to 25.  The most
significant pattern Dorsey looked for was a &ldquo;reversal bulge&rdquo; where the index
goes above 27 then falls back below 26.5, indicating a widening of daily
trading range and suggesting a reversal in price is likely.
</p>
<a class="index-entry-id" id="index-EMA-of-EMA"></a>
<a class="index-entry-id" id="index-Double-exponential-moving-average-1"></a>
<a class="index-entry-id" id="index-Average_002c-double-exponential-1"></a>
<a class="index-entry-id" id="index-Moving-average_002c-double-exponential-1"></a>
<a class="anchor" id="EMA-of-EMA"></a></div>
<div class="section-level-extent" id="EMA-of-EMA-1">
<h3 class="section"><span>10.23 EMA of EMA<a class="copiable-link" href="#EMA-of-EMA-1"> &para;</a></span></h3>

<p>Applying an EMA a second time gives a quite different result from a plain
EMA.  It&rsquo;s still a weighted average of recent prices, but whereas a plain EMA
is dominated by the most recent prices, a double EMA spreads more broadly, and
the latest few days&rsquo; influence is in fact smaller than the peak weights (at
about N/2 days back).  The following graph shows the weights for <em class="math">N=10</em>.
</p>
<br>
<div class="center"><img class="image" src="chart-ema-2-weights.png" alt="EMA of EMA weights graph">
</div>
<p>The twice-smoothed EMA is also available directly as a moving average option,
under &ldquo;Low Priority&rdquo; in the indicator lists, to see its effect on prices or
on an oscillator.
</p>

<hr>
</div>
<div class="section-level-extent" id="Momentum-and-Rate-of-Change">
<div class="nav-panel">
<p>
Next: <a href="#Money-Flow-Index" accesskey="n" rel="next">Money Flow Index</a>, Previous: <a href="#MASS-Index" accesskey="p" rel="prev">MASS Index</a>, Up: <a href="#Indicators" accesskey="u" rel="up">Indicators</a> &nbsp; [<a href="#Concept-Index"...
</div>
<h3 class="section" id="Momentum"><span>10.24 Momentum<a class="copiable-link" href="#Momentum"> &para;</a></span></h3>
<a class="index-entry-id" id="index-Momentum"></a>
<a class="index-entry-id" id="index-Rate-of-change"></a>
<a class="index-entry-id" id="index-ROC"></a>

<p>Momentum and rate of change show a difference between today&rsquo;s close and the
close N days ago.  Momentum is the difference as a price amount (positive or
negative), rate of change scales it to a percentage increase or decrease from
that N-day ago close.  This scaling is an advantage if comparing past times
when prices levels were much higher or lower than now.  If p1 is today,
p2 yesterday, etc, then
</p>
<div class="example">
<pre class="example-preformatted">Momentum = p[1] - p[N+1]

            p[1] - p[N+1]
ROC = 100 * -------------
               p[N+1]
</pre></div>

<p>It will be noticed that momentum is the difference between an N-day simple
moving average (see <a class="pxref" href="#Simple-Moving-Average">Simple Moving Average</a>) for today and yesterday, with a
scale factor N, ie.
</p>
<div class="example">
<pre class="example-preformatted">Momentum
-------- = SMA[today] - SMA[yesterday]
   N
</pre></div>

<p>This is the slope of the SMA line (price change per day) at that point.
Momentum crosses up through zero when SMA makes a peak, or down through zero
when SMA makes a trough.  The TRIX indicator (see <a class="pxref" href="#TRIX">TRIX</a>) does a similar
thing with a triple exponential moving average.
</p>
<ul class="mini-toc">
<li><a href="#Additional-Resources-7" accesskey="1">Additional Resources</a></li>
</ul>
<div class="subsection-level-extent" id="Additional-Resources-7">
<h4 class="subsection"><span>10.24.1 Additional Resources<a class="copiable-link" href="#Additional-Resources-7"> &para;</a></span></h4>

<ul class="itemize mark-bullet">
<li><a class="uref" href="http://trader.online.pl/MSZ/e-w-Chandes_Trendscore.html">http://trader.online.pl/MSZ/e-w-Chandes_Trendscore.html</a> &ndash; Formula and
sample on Polish WIG20 from 2000.
</li></ul>


<hr>
</div>
</div>
<div class="section-level-extent" id="Money-Flow-Index">
<div class="nav-panel">
<p>
Next: <a href="#On_002dBalance-Volume" accesskey="n" rel="next">On-Balance Volume</a>, Previous: <a href="#Momentum-and-Rate-of-Change" accesskey="p" rel="prev">Momentum</a>, Up: <a href="#Indicators" accesskey="u" rel="up">Indicators</a> &nbsp; [<a ...
</div>
<h3 class="section" id="Money-Flow-Index-1"><span>10.25 Money Flow Index<a class="copiable-link" href="#Money-Flow-Index-1"> &para;</a></span></h3>
<a class="index-entry-id" id="index-Money-Flow-Index"></a>
<a class="index-entry-id" id="index-MFI"></a>
<a class="index-entry-id" id="index-Index_002c-money-flow"></a>

<p>The Money Flow Index (MFI) ranges from 0 to 100 showing dollar volume
(referred to as &ldquo;money flow&rdquo;) on up days as a percentage of total up and
down days, in a given past N days.
</p>
<p>The calculation is as follows.  A &ldquo;typical price&rdquo; is formed from the average
of high, low and close.  If high/low figures are not available then Chart just
uses the close,
</p>
<div class="example">
<pre class="example-preformatted">                high + low + close
typical price = ------------------
                        3
</pre></div>

<p>&ldquo;Money flow&rdquo; on a given day is typical price multiplied by volume.  This is
the money that flowed, ie. an approximation to the dollar volume traded.
</p>
<div class="example">
<pre class="example-preformatted">money flow = typical price * volume
</pre></div>

<p>Across the N-day period two totals are formed.  &ldquo;Positive money flow&rdquo; is the
money flow on days where the typical price is higher the previous day&rsquo;s
typical price, and &ldquo;negative money flow&rdquo; when below.  Days when typical
price is unchanged are ignored.  The MFI is then
</p>
<div class="example">
<pre class="example-preformatted">                      positive money flow
MFI = 100 * -----------------------------------------
            positive money flow + negative money flow
</pre></div>

<p>Generally an MFI level of 80 is considered overbought, and 20 considered
oversold.  Those levels are shown as shown as dashed lines.
</p>
<p>MFI is similar to RSI (see <a class="pxref" href="#Relative-Strength-Index">Relative Strength Index</a>) in its construction
and use.  Both are looking at up days versus totalled up and down days, but
the RSI scales by price change amounts where MFI scales on dollar volume (or
an approximation to that).
</p>



( run in 1.446 second using v1.01-cache-2.11-cpan-39bf76dae61 )