code: def test_EncoderNormalizer_with_limited_history():
      data = torch.rand(100)
      normalizer = EncoderNormalizer(max_length=[1, 2]).fit(data)
      assert normalizer.center_ == data[-1]
  
file_path: pytorch-forecasting/tests/test_data/test_encoders.py
imports: from copy import deepcopy
  import itertools
  import numpy
  import pandas
  import pytest
  from sklearn.utils.validation import NotFittedError, check_is_fitted
  import torch
  from pytorch_forecasting.data import EncoderNormalizer, GroupNormalizer, MultiNormalizer, NaNLabelEncoder, TorchNormalizer
label_desc: Use image node_id 5 for calling a global function with example usage: test_EncoderNormalizer_with_limited_history() without return types