def METHOD_NAME(self, y, x=None):
    if self._initialized:
        self.level.update(y, self.trend, self.season)
        if self.trend is not None:
            self.trend.update(y, self.level)
        if self.season is not None:
            self.season.update(y, self.level, self.trend)
        return self
    self._first_values.append(y)
    if len(self._first_values) < max(2, self.seasonality):
        return self
    # The components can be initialized now that enough values have been observed
    self.level.append(statistics.mean(self._first_values))
    diffs = [b - a for a, b in zip(self._first_values[:-1], self._first_values[1:])]
    if self.trend is not None:
        self.trend.append(statistics.mean(diffs))
    if self.season is not None:
        self.season.extend([y / self.level[-1] for y in self._first_values])
    self._initialized = True
    return self