test_class.file: jtstoolkit/src/test/java/ec/tstoolkit/timeseries/regression/SeasonalOutlierTest.java
test_class.identifier: SeasonalOutlierTest
test_case.body: @Test
      public void testAround() {
          TsPeriod pos = new TsPeriod(TsFrequency.Monthly, 2000, 3);
          SeasonalOutlier so1 = new SeasonalOutlier(pos.firstday());
          // 
          for (int i = -6; i < 6; ++i) {
              DataBlock data = new DataBlock(12);
              so1.data(pos.minus(i), data);
          }
      }
test_case.class_method_signature: SeasonalOutlierTest.testAround()
test_case.full_signature: @Test public void testAround()
test_case.identifier: testAround
test_case.invocations: firstday data minus
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testAround()
focal_class.declarator: CODE="SO"
focal_class.modifier: public static final
focal_class.original_string: public static final String CODE="SO";
focal_class.type: String
focal_class.var_name: CODE
focal_class.declarator: zeroEnded
focal_class.original_string: boolean zeroEnded;
focal_class.type: boolean
focal_class.var_name: zeroEnded
focal_class.file: jtstoolkit/src/main/java/ec/tstoolkit/timeseries/regression/SeasonalOutlier.java
focal_class.identifier: SeasonalOutlier
focal_class.class_method_signature: SeasonalOutlier.SeasonalOutlier(Day pos)
focal_class.full_signature: public  SeasonalOutlier(Day pos)
focal_class.identifier: SeasonalOutlier
focal_class.modifiers: public
focal_class.parameters: (Day pos)
focal_class.signature:  SeasonalOutlier(Day pos)
focal_class.class_method_signature: SeasonalOutlier.data(TsPeriod start, DataBlock data)
focal_class.full_signature: @Override public void data(TsPeriod start, DataBlock data)
focal_class.identifier: data
focal_class.modifiers: @Override public
focal_class.parameters: (TsPeriod start, DataBlock data)
focal_class.return: void
focal_class.signature: void data(TsPeriod start, DataBlock data)
focal_class.class_method_signature: SeasonalOutlier.getOutlierType()
focal_class.full_signature: @Override public OutlierType getOutlierType()
focal_class.identifier: getOutlierType
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: OutlierType
focal_class.signature: OutlierType getOutlierType()
focal_class.class_method_signature: SeasonalOutlier.getCode()
focal_class.full_signature: public String getCode()
focal_class.identifier: getCode
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getCode()
focal_class.class_method_signature: SeasonalOutlier.isSignificant(TsDomain domain)
focal_class.full_signature: @Override public boolean isSignificant(TsDomain domain)
focal_class.identifier: isSignificant
focal_class.modifiers: @Override public
focal_class.parameters: (TsDomain domain)
focal_class.return: boolean
focal_class.signature: boolean isSignificant(TsDomain domain)
focal_class.class_method_signature: SeasonalOutlier.isZeroEnded()
focal_class.full_signature: public boolean isZeroEnded()
focal_class.identifier: isZeroEnded
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: boolean
focal_class.signature: boolean isZeroEnded()
focal_class.class_method_signature: SeasonalOutlier.setZeroEnded(boolean value)
focal_class.full_signature: public void setZeroEnded(boolean value)
focal_class.identifier: setZeroEnded
focal_class.modifiers: public
focal_class.parameters: (boolean value)
focal_class.return: void
focal_class.signature: void setZeroEnded(boolean value)
focal_class.class_method_signature: SeasonalOutlier.getFilterRepresentation(int freq)
focal_class.full_signature: @Override public FilterRepresentation getFilterRepresentation(int freq)
focal_class.identifier: getFilterRepresentation
focal_class.modifiers: @Override public
focal_class.parameters: (int freq)
focal_class.return: FilterRepresentation
focal_class.signature: FilterRepresentation getFilterRepresentation(int freq)
focal_class.superclass: extends AbstractOutlierVariable
focal_method.body: @Override
      public void data(TsPeriod start, DataBlock data) {
          TsPeriod pstart=new TsPeriod(start.getFrequency(), position);
          int pos = pstart.minus(start);
          data.set(0);
          int freq = start.getFrequency().intValue();
  
          double z = -1.0 / (freq - 1);
          int xpos;
          int len = data.getLength();
          if (zeroEnded) {
              int j = 1;
              if (pos < 0) {
                  return;
              } else if (pos > len) {
                  int n = pos - len;
                  j = 1 + n % freq;
                  xpos = len;
              } else {
                  xpos = pos;
              }
              do {
                  for (; j < freq && xpos > 0; ++j) {
                      data.set(--xpos, z);
                  }
                  if (xpos > 0) {
                      data.set(--xpos, 1);
                  } else {
                      break;
                  }
                  j = 1;
              } while (true);
          } else {
              if (pos < 0) {
                  xpos = pos % freq;
              } else {
                  xpos = pos;
              }
              if (xpos < 0) {
                  int max=Math.min(len, freq + xpos);
                  for (int j = 0; j < max; ++j) {
                      data.set(j, z);
                  }
                  xpos += freq;
  
              }
  
              for (int i = xpos; i < len;) {
                  data.set(i++, 1);
                  for (int j = 1; j < freq && i < len; ++i, ++j) {
                      data.set(i, z);
                  }
              }
          }
      }
focal_method.class_method_signature: SeasonalOutlier.data(TsPeriod start, DataBlock data)
focal_method.full_signature: @Override public void data(TsPeriod start, DataBlock data)
focal_method.identifier: data
focal_method.invocations: getFrequency minus set intValue getFrequency getLength set set min set set set
focal_method.modifiers: @Override public
focal_method.parameters: (TsPeriod start, DataBlock data)
focal_method.return: void
focal_method.signature: void data(TsPeriod start, DataBlock data)