class_docstr: TargetEncoder
docstr: Data leakage handling strategy used to generate the encoding. Supported options are:
  1) "none" (default) - no holdout, using the entire training frame.
  2) "leave_one_out" - current row's response value is subtracted from the per-level frequencies pre-calculated on
  the entire training frame.
  3) "k_fold" - encodings for a fold are generated based on out-of-fold data.
  
  Type: ``Literal["leave_one_out", "k_fold", "none"]``, defaults to ``"none"``.
  
  :examples:
  
  >>> titanic = h2o.import_file("https://s3.amazonaws.com/h2o-public-test-data/smalldata/gbm_test/titanic.csv")
  >>> predictors = ["home.dest", "cabin", "embarked"]
  >>> response = "survived"
  >>> titanic["survived"] = titanic["survived"].asfactor()
  >>> fold_col = "kfold_column"
  >>> titanic[fold_col] = titanic.kfold_column(n_folds=5, seed=1234)
  >>> titanic_te = H2OTargetEncoderEstimator(inflection_point=35,
  ...                                        smoothing=25,
  ...                                        data_leakage_handling="k_fold",
  ...                                        blending=True)
  >>> titanic_te.train(x=predictors,
  ...                  y=response,
  ...                  training_frame=titanic)
  >>> titanic_te
docstr_tok: ["Data","leakage","handling","strategy","used","to","generate","the","encoding",".","Supported","options","are",":","1",")","``","none","''","(","default",")","-","no","holdout",",","using","the","entire","training","frame",".","2",")","``","leave_one_out","''","-","current","row","'s","response","value","is","subtracted","from","the","per-level","frequencies","pre-calculated","on","the","entire","training","frame",".","3",")","``","k_fold","''","-","encodings","for","a","fold","are","generated","based","on","out-of-fold","data",".","Type",":","``","Literal","[","``","leave_one_out","''",",","``","k_fold","''",",","``","none","''","]","``",",","defaults","to","``","``","none","''","``",".",":","examples",":",">",">",">","titanic","=","h2o.import_file","(","``","https",":","\/\/s3.amazonaws.com\/h2o-public-test-data\/smalldata\/gbm_test\/titanic.csv","''",")",">",">",">","predictors","=","[","``","home.dest","''",",","``","cabin","''",",","``","embarked","''","]",">",">",">","response","=","``","survived","''",">",">",">","titanic","[","``","survived","''","]","=","titanic","[","``","survived","''","]",".asfactor","(",")",">",">",">","fold_col","=","``","kfold_column","''",">",">",">","titanic","[","fold_col","]","=","titanic.kfold_column","(","n_folds=5",",","seed=1234",")",">",">",">","titanic_te","=","H2OTargetEncoderEstimator","(","inflection_point=35",",","...","smoothing=25",",","...","data_leakage_handling=","''","k_fold","''",",","...","blending=True",")",">",">",">","titanic_te.train","(","x=predictors",",","...","y=response",",","...","training_frame=titanic",")",">",">",">","titanic_te"]
code: def data_leakage_handling(self):
      """
      Data leakage handling strategy used to generate the encoding. Supported options are:
      1) "none" (default) - no holdout, using the entire training frame.
      2) "leave_one_out" - current row's response value is subtracted from the per-level frequencies pre-calculated on
      the entire training frame.
      3) "k_fold" - encodings for a fold are generated based on out-of-fold data.
  
      Type: ``Literal["leave_one_out", "k_fold", "none"]``, defaults to ``"none"``.
  
      :examples:
  
      >>> titanic = h2o.import_file("https://s3.amazonaws.com/h2o-public-test-data/smalldata/gbm_test/titanic.csv")
      >>> predictors = ["home.dest", "cabin", "embarked"]
      >>> response = "survived"
      >>> titanic["survived"] = titanic["survived"].asfactor()
      >>> fold_col = "kfold_column"
      >>> titanic[fold_col] = titanic.kfold_column(n_folds=5, seed=1234)
      >>> titanic_te = H2OTargetEncoderEstimator(inflection_point=35,
      ...                                        smoothing=25,
      ...                                        data_leakage_handling="k_fold",
      ...                                        blending=True)
      >>> titanic_te.train(x=predictors,
      ...                  y=response,
      ...                  training_frame=titanic)
      >>> titanic_te
      """
      return self._parms.get("data_leakage_handling")
  
imports: from h2o.utils.metaclass import deprecated_params, deprecated_property
  import h2o
  import warnings
  from h2o.exceptions import H2ODeprecationWarning
  from h2o.utils.typechecks import U
  from h2o.estimators.estimator_base import H2OEstimator
  from h2o.exceptions import H2OValueError
  from h2o.frame import H2OFrame
  from h2o.utils.typechecks import assert_is_type, Enum, numeric
label_desc: Use image node_id 20 for calling the H2OTargetEncoderEstimator obj's underlying member method code with example usage: obj.data_leakage_handling() and returns: self