class_docstr: Apply a transformer columnwise to multivariate series.
  
  Overview: input multivariate time series and the transformer passed
  in `transformer` parameter is applied to specified `columns`, each
  column is handled as a univariate series. The resulting transformed
  data has the same shape as input data.
  
  Parameters
  ----------
  transformer : Estimator
      scikit-learn-like or sktime-like transformer to fit and apply to series.
  columns : list of str or None
          Names of columns that are supposed to be transformed.
          If None, all columns are transformed.
  
  Attributes
  ----------
  transformers_ : dict of {str : transformer}
      Maps columns to transformers.
  columns_ : list of str
      Names of columns that are supposed to be transformed.
  
  See Also
  --------
  OptionalPassthrough
  
  Examples
  --------
  >>> from sktime.datasets import load_longley
  >>> from sktime.transformations.series.detrend import Detrender
  >>> from sktime.transformations.compose import ColumnwiseTransformer
  >>> _, X = load_longley()
  >>> transformer = ColumnwiseTransformer(Detrender())
  >>> Xt = transformer.fit_transform(X)
docstr: Fit transformer to X and y.
  
  private _fit containing the core logic, called from fit
  
  Parameters
  ----------
  X : pd.DataFrame
      Data to fit transform to
  y : Series or Panel, default=None
      Additional data, e.g., labels for transformation
  
  Returns
  -------
  self: a fitted instance of the estimator
docstr_tok: ["Fit","transformer","to","X","and","y.","private","_fit","containing","the","core","logic",",","called","from","fit","Parameters","--","--","--","--","--","X",":","pd.DataFrame","Data","to","fit","transform","to","y",":","Series","or","Panel",",","default=None","Additional","data",",","e.g.",",","labels","for","transformation","Returns","--","--","--","-","self",":","a","fitted","instance","of","the","estimator"]
code: def _fit(self, X, y=None):
      """Fit transformer to X and y.
  
      private _fit containing the core logic, called from fit
  
      Parameters
      ----------
      X : pd.DataFrame
          Data to fit transform to
      y : Series or Panel, default=None
          Additional data, e.g., labels for transformation
  
      Returns
      -------
      self: a fitted instance of the estimator
      """
      # check that columns are None or list of strings
      if self.columns is not None:
          if not isinstance(self.columns, list) and all(
              isinstance(s, str) for s in self.columns
          ):
              raise ValueError(
                  "Columns need to be a list of strings or None."
              )
  
      # set self.columns_ to columns that are going to be transformed
      # (all if self.columns is None)
      self.columns_ = self.columns
      if self.columns_ is None:
          self.columns_ = X.columns
  
      # make sure z contains all columns that the user wants to transform
      _check_columns(X, selected_columns=self.columns_)
  
      # fit by iterating over columns
      self.transformers_ = {}
      for colname in self.columns_:
          transformer = self.transformer.clone()
          self.transformers_[colname] = transformer
          self.transformers_[colname].fit(X[colname], y)
      return self
  
imports: import pandas
  from sktime.base._meta import _ColumnEstimator, _HeterogenousMetaEstimator
  from sktime.transformations.base import BaseTransformer
  from sktime.utils.multiindex import rename_multiindex
  from sktime.utils.validation.series import check_series
label_desc: Use image node_id 2 for calling the ColumnwiseTransformer obj's underlying member method code with example usage: obj._fit(X, y) and returns: self