PINE LIBRARY

Tosch Stacked EMAs (Fibonacci)

Updated
Library "Tosch_Stacked_EMAs (Fibonacci)"

stacked()
  Returns true if all EMAs are stacked, either way.

bullish()
  Returns true if the EMAs are stacked bullish, false otherwise

emas()
  Returns the EMA values for lengths 5, 8, 13, 21, 34, 55, 89
Release Notes
v2 - added inputs for display of lines and coloring the bars
Release Notes
v3
Added ema34 in array of returned EMA values
Release Notes
v4
changed the colors of the lines and emphasized the 21 EMA as white dots
Release Notes
v5

emas()
Returns the EMA values for lengths 5, 8, 13, 21, 34, 55, 89

stacked()
Returns true if all EMAs are stacked, either way.

bullish()
bearish()
Returns true if the EMAs are stacked bullish/bearish, false otherwise

bear_count()
bull_count()
Returns the number of stacked EMAs

bull_bool_array()
Returns the arrays of the true/false values if one EMA is below/above the next one
- bear: [ (ema05<=ema08), (ema08<=ema13), (ema13<=ema21), (ema21<=ema34), (ema34<=ema55), (ema55<=ema89) ]
- bull: [ (ema05>=ema08), (ema08>=ema13), (ema13>=ema21), (ema21>=ema34), (ema34>=ema55), (ema55>=ema89) ]
airshippirateExponential Moving Average (EMA)stackedstackedematechindicatortosch

Pine library

In true TradingView spirit, the author has published this Pine code as an open-source library so that other Pine programmers from our community can reuse it. Cheers to the author! You may use this library privately or in other open-source publications, but reuse of this code in a publication is governed by House rules.

Disclaimer