code: def test_catBoost_missing(self):
      X = pd.DataFrame(
          {"col1": ["A", "B", "B", "C", "A", np.NaN, np.NaN, np.NaN]}
      )
      y = pd.Series([1, 0, 1, 0, 1, 0, 1, 0])
      enc = encoders.CatBoostEncoder(handle_missing="value")
      obtained = enc.fit_transform(X, y)
      self.assertEqual(
          list(obtained["col1"]),
          [0.5, 0.5, 0.5 / 2, 0.5, 1.5 / 2, 0.5, 0.5 / 2, 1.5 / 3],
          "We treat None as another category.",
      )
  
      X_t = pd.DataFrame({"col1": ["B", "B", "A", np.NaN]})
      obtained = enc.transform(X_t)
      self.assertEqual(
          list(obtained["col1"]), [1.5 / 3, 1.5 / 3, 2.5 / 3, 1.5 / 4]
      )
  
file_path: category_encoders/tests/test_cat_boost.py
imports: import pandas
  import numpy
  from unittest import TestCase
  import category_encoders
label_desc: Use image node_id 2 for calling the TestCatBoostEncoder obj's underlying member method code with example usage: obj.test_catBoost_missing() without return types