Firetron’s Candle

3 846 Views 2 Comments 4 years ago
  • Creates and returns a Candle Class instance. Note that every property is a getter function.

    Test Script

    function Test()
      local closePrices = ClosePrices()
      local highPrices  = HighPrices()
      local lowPrices   = LowPrices()
      local openPrices  = OpenPrices()
      local candle      = CC_Candle(openPrices, highPrices, lowPrices, closePrices)
      Log('-----------')
      Log('Next Candle')
      Log('-----------')
      Log('IsGreen: '..Parse(candle.IsGreen(), StringType))
      Log('IsRed: '..Parse(candle.IsRed(), StringType))
      Log('IsDoji: '..Parse(candle.IsDoji(), StringType))
      Log('IsDragonfly: '..Parse(candle.IsDragonfly(), StringType))
      Log('IsGravestone: '..Parse(candle.IsGravestone(), StringType))
      Log('IsLongLegged: '..Parse(candle.IsLongLegged(), StringType))
      Log('Full: '..candle.Full())
      Log('Body: '..candle.Body())
      Log('Wicks: '..candle.Wicks())
      Log('TopWick: '..candle.TopWick())
      Log('BottomWick: '..candle.BottomWick())
      Log('WithoutTopWick: '..candle.WithoutTopWick())
      Log('WithoutBottomWick: '..candle.WithoutBottomWick())
    end
    OptimizedForInterval(360, Test)
    HaasScript Code
    Sign in or Register to download for free
    • #1615
      Kobalt
      Basic
      Up
      1
      Down
      ::

      KABOOM! great!

    • #1619
      pshai
      Admin
      Up
      1
      Down
      ::

      Nice work! This is great for breaking down candles.

Login or Register to Comment

Unlock your crypto trading potential

Create a free account and enjoy everything we have to offer.

Join for Free