docstr: Check transform
docstr_tok: ["Check","transform"]
code: def test_transform(self):
      """
      Check transform
      """
      # training data
      d = {
          "col1": [1, 2, 3, np.nan, np.nan],
          "col2": ["a", "a", np.nan, "a", "c"],
          "col3": [1, 1, 3, 1, 1],
          "col4": ["a", "a", "a", "c", "a"],
      }
      df = pd.DataFrame(data=d)
      # test data
      d_test = {
          "col1": [1, 2, 3, np.nan, np.nan],
          "col2": ["b", "b", np.nan, "b", "c"],
          "col3": [1, 2, 2, np.nan, 2],
          "col4": ["b", "b", np.nan, "b", "c"],
      }
      df_test = pd.DataFrame(data=d_test)
      # fill with median
      preprocess_missing = PreprocessingMissingValues(
          df.columns, PreprocessingMissingValues.FILL_NA_MEDIAN
      )
      preprocess_missing.fit(df)
      self.assertEqual(
          2, len(preprocess_missing._na_fill_params)
      )  # there should be only two columns
      df_transformed = preprocess_missing.transform(df_test)
      self.assertTrue(
          np.isnan(df.loc[3, "col1"])
      )  # training data frame is not filled
      self.assertEqual(
          2, df_test.loc[3, "col1"]
      )  # data frame is filled after transform
      self.assertEqual("a", df_test.loc[2, "col2"])
  
file_path: mljar-supervised/tests/tests_preprocessing/test_preprocessing_missing.py
imports: import unittest
  import tempfile
  import numpy
  import pandas
  from supervised.preprocessing.preprocessing_utils import PreprocessingUtils
  from supervised.preprocessing.preprocessing_missing import PreprocessingMissingValues
label_desc: Use image node_id 4 for calling the PreprocessingMissingValuesTest obj's underlying member method code with example usage: obj.test_transform() without return types