#include "simple_indicator.hh"

#include "sma.hh"
#include <cassert>
#include <algorithm>

namespace AI {

SimpleIndicator::SimpleIndicator(int period) :
    period_(period)
{
    for (int i = 0; i < period_; i++)
        buffer_.push_back(0.0);
}

void SimpleIndicator::clearBuffer()
{
    buffer_.clear();

    for (int i = 0; i < period_; i++)
        buffer_.push_back(0.0);
}

}
