class SeasonalDummies implements ITsVariable {

    @Override
    public void data(TsDomain domain, List<DataBlock> data) {
        int pstart = domain.getStart().getPosition();
        int ifreq = domain.getFrequency().intValue();
        int lstart = ifreq - pstart - 1;
        if (lstart < 0) {
            lstart += ifreq;
        }
        for (int i = 0; i < ifreq - 1; i++) {
            DataBlock x = data.get(i);
            int jstart = i - pstart;
            if (jstart < 0) {
                jstart += ifreq;
            }
            DataBlock m = x.extract(jstart, -1, ifreq);
            m.set(1);
            DataBlock q = x.extract(lstart, -1, ifreq);
            q.set(-1);
        }
    }

    public  SeasonalDummies(TsFrequency freq);

}