Mulitime Frame trend
Practical Example: Carbon Future
    The following chart shows the carbon future on a 10 minute basis. Below the chart you can see the
    Multiple Time Frame Trend Visualiser at work: The three lines show the trend status of the chosen
    chart time frame (10 minutes), the hourly and the daily period. To keep it simple, we used an SMA
    with 100 periods to define the trend. This way, you are always informed what is happening on higher
    time frames which provides you a better overall perspective.
    Now let us take a look at the Equilla code. As mentioned before, we use an SMA here, but of course
    you can insert any other trend criteria you prefer here.
   In lines 5-7 we define our trend criteria – here we stick with the SMA. We use the data1 function to
    call up different time frames like hourly and daily (see also here).
   Lines 9-14 assign colors based on each time frame – red (price below SMA) or green (price above
    SMA)
   In lines 20-22 we use the function calles pricemarkeralignaxis to draw text labels for our indicator.
Moving Average Chart over a Season
Outperformance Indicator Code
Stiffness Indicator
Trendless Market
The rules are pretty simple: When the market is below a specific ADX threshold, then the market is
trendless and we want to display Bollinger Bands on the charts or an n-bar high low channel or colour
the background of the chart. Here`s an example of the indicator will look like: In the upper subchart
you can see the Bollinger Bands when the market is trendless, while the lower subchart draws a 20-
bar-high-low channel.
    Let`s code it!
   In line 4, please notice the variable called flags which will be used for colouring the background of the
    chart
   The variables for the upper and lower band of the Bollinger indicator are declared in line 7 and 8
   In line 10, the built-in function for the ADX is used in the if-then-statement
     If the ADX is lower than the value set in the input section, then either the Bollinger Bands or the
         high-low-channel or the coloured background is drawn.
     The input “style” (line 3) acts as a switch here.
   Line 17 and 18 are responsible for the high-low-channel. For this purpose, we use the highest high
    value (hhv) and lowest low value (llv) function
     If you would like to use a flexible value instead of 20 bars, you can add an input and then replace
         20 with the input
   In line 22 you can see the command for colouring the background using the flags variable from line 4
    Trend Filter
Bars Since Last High
I would like to give you a small piece of code to show you how the programming is done. The
question is: How many days has it been, since the market made its last 25 day high. The chart above
shows you the result. The indicator always rises 1 per day if there is no new 25 bar high, and is reset
to zero if there has been a new high.