class_docstr: Standardizes features by removing the mean and scaling to unit variance using column summary
  statistics on the samples in the training set.
  
  .. versionadded:: 3.5.0
  
  Examples
  --------
  >>> from pyspark.ml.connect.feature import StandardScaler
  >>> scaler = StandardScaler(inputCol='features', outputCol='scaled_features')
  >>> dataset = spark.createDataFrame([
  ...     ([1.0, 2.0],),
  ...     ([2.0, -1.0],),
  ...     ([-3.0, -2.0],),
  ... ], schema=['features'])
  >>> scaler_model = scaler.fit(dataset)
  >>> transformed_dataset = scaler_model.transform(dataset)
  >>> transformed_dataset.show(truncate=False)
  +------------+------------------------------------------+
  |features    |scaled_features                           |
  +------------+------------------------------------------+
  |[1.0, 2.0]  |[0.3779644730092272, 1.1208970766356101]  |
  |[2.0, -1.0] |[0.7559289460184544, -0.3202563076101743] |
  |[-3.0, -2.0]|[-1.1338934190276817, -0.8006407690254358]|
  +------------+------------------------------------------+
class_docstr_tok: ["Standardizes","features","by","removing","the","mean","and","scaling","to","unit","variance","using","column","summary","statistics","on","the","samples","in","the","training","set",".","..","versionadded",":",":","3.5.0","Examples","--","--","--","--",">",">",">","from","pyspark.ml.connect.feature","import","StandardScaler",">",">",">","scaler","=","StandardScaler","(","inputCol='features","'",",","outputCol='scaled_features","'",")",">",">",">","dataset","=","spark.createDataFrame","(","[","...","(","[","1.0",",","2.0","]",",",")",",","...","(","[","2.0",",","-1.0","]",",",")",",","...","(","[","-3.0",",","-2.0","]",",",")",",","...","]",",","schema=","[","'features","'","]",")",">",">",">","scaler_model","=","scaler.fit","(","dataset",")",">",">",">","transformed_dataset","=","scaler_model.transform","(","dataset",")",">",">",">","transformed_dataset.show","(","truncate=False",")","+","--","--","--","--","--","--","+","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","+","|features","|scaled_features","|","+","--","--","--","--","--","--","+","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","+","|","[","1.0",",","2.0","]","|","[","0.3779644730092272",",","1.1208970766356101","]","|","|","[","2.0",",","-1.0","]","|","[","0.7559289460184544",",","-0.3202563076101743","]","|","|","[","-3.0",",","-2.0","]","|","[","-1.1338934190276817",",","-0.8006407690254358","]","|","+","--","--","--","--","--","--","+","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","--","+"]
code: def _fit(
      self, dataset: Union[DataFrame, pd.DataFrame]
  ) -> "StandardScalerModel":
      input_col = self.getInputCol()
  
      stat_result = summarize_dataframe(
          dataset, input_col, ["mean", "std", "count"]
      )
      mean_values = stat_result["mean"]
      std_values = stat_result["std"]
      n_samples_seen = stat_result["count"]
  
      model = StandardScalerModel(
          mean_values, std_values, n_samples_seen
      )
      model._resetUid(self.uid)
      return self._copyValues(model)
  
imports: import pickle
  from typing import Any, Union, List, Tuple, Callable, Dict, Optional
  import numpy
  import pandas
  from pyspark import keyword_only
  from pyspark.sql import DataFrame
  from pyspark.ml.param.shared import HasInputCol, HasInputCols, HasOutputCol, HasFeatureSizes, HasHandleInvalid, Param, Params, TypeConverters
  from pyspark.ml.connect.base import Estimator, Model, Transformer
  from pyspark.ml.connect.io_utils import ParamsReadWrite, CoreModelReadWrite
  from pyspark.ml.connect.summarizer import summarize_dataframe
label_desc: Use image node_id 2 for calling the StandardScaler obj's underlying member method code with example usage: obj._fit(dataset) and returns: self