require "Color"
require "TIlib"

$Names[0] = "EMA(13)"
$Colors[0] = $Red
$Names[1] = "EMA(26)"
$Colors[1] = $Green

Volume_draw($Blue)

if !$EMA1
    $EMA1 = VolumeEMA_new(13)
    $EMA2 = VolumeEMA_new(26)
else
    VolumeEMA_next($EMA1)
    VolumeEMA_draw($EMA1, $Colors[0])
    VolumeEMA_next($EMA2)
    VolumeEMA_draw($EMA2, $Colors[1])
end
Indicator(0, $EMA1[1])
Indicator(1, $EMA2[1])
