class_docstr: The WoEEncoder() replaces categories by the weight of evidence
  (WoE). The WoE was used primarily in the financial sector to create credit risk
  scorecards.
  
  The encoder will encode only categorical variables by default
  (type 'object' or 'categorical'). You can pass a list of variables to encode.
  Alternatively, the encoder will find and encode all categorical variables
  (type 'object' or 'categorical').
  
  With `ignore_format=True` you have the option to encode numerical variables as well.
  The procedure is identical, you can either enter the list of variables to encode, or
  the transformer will automatically select all variables.
  
  The encoder first maps the categories to the weight of evidence for each variable
  (fit). The encoder then transforms the categories into the mapped numbers
  (transform).
  
  This categorical encoding is exclusive for binary classification.
  
  **Note**
  
  The log(0) is not defined and the division by 0 is not defined. Thus, if any of the
  terms in the WoE equation are 0 for a given category, the encoder will return an
  error. If this happens, try grouping less frequent categories.
  
  More details in the :ref:`User Guide <woe_encoder>`.
  
  Parameters
  ----------
  {variables}
  
  {ignore_format}
  
  {unseen}
  
  Attributes
  ----------
  encoder_dict_:
      Dictionary with the WoE per variable.
  
  {variables_}
  
  {feature_names_in_}
  
  {n_features_in_}
  
  Methods
  -------
  fit:
      Learn the WoE per category, per variable.
  
  {transform}
  
  {fit_transform}
  
  {inverse_transform}
  
  Notes
  -----
  For details on the calculation of the weight of evidence visit:
  https://www.listendata.com/2015/03/weight-of-evidence-woe-and-information.html
  
  NAN are introduced when encoding categories that were not present in the training
  dataset. If this happens, try grouping infrequent categories using the
  RareLabelEncoder().
  
  There is a similar implementation in the the open-source package
  `Category encoders <https://contrib.scikit-learn.org/category_encoders/>`_
  
  See Also
  --------
  feature_engine.encoding.RareLabelEncoder
  feature_engine.discretisation
  category_encoders.woe.WOEEncoder
  
  Examples
  --------
  
  >>> import pandas as pd
  >>> from feature_engine.encoding import WoEEncoder
  >>> X = pd.DataFrame(dict(x1 = [1,2,3,4,5], x2 = ["b", "b", "b", "a", "a"]))
  >>> y = pd.Series([0,1,1,1,0])
  >>> woe = WoEEncoder()
  >>> woe.fit(X, y)
  >>> woe.transform(X)
     x1        x2
  0   1  0.287682
  1   2  0.287682
  2   3  0.287682
  3   4 -0.405465
  4   5 -0.405465
class_docstr_tok: ["The","WoEEncoder","(",")","replaces","categories","by","the","weight","of","evidence","(","WoE",")",".","The","WoE","was","used","primarily","in","the","financial","sector","to","create","credit","risk","scorecards",".","The","encoder","will","encode","only","categorical","variables","by","default","(","type","'object","'","or","'categorical","'",")",".","You","can","pass","a","list","of","variables","to","encode",".","Alternatively",",","the","encoder","will","find","and","encode","all","categorical","variables","(","type","'object","'","or","'categorical","'",")",".","With","`","ignore_format=True","`","you","have","the","option","to","encode","numerical","variables","as","well",".","The","procedure","is","identical",",","you","can","either","enter","the","list","of","variables","to","encode",",","or","the","transformer","will","automatically","select","all","variables",".","The","encoder","first","maps","the","categories","to","the","weight","of","evidence","for","each","variable","(","fit",")",".","The","encoder","then","transforms","the","categories","into","the","mapped","numbers","(","transform",")",".","This","categorical","encoding","is","exclusive","for","binary","classification",".","*","*","Note","*","*","The","log","(","0",")","is","not","defined","and","the","division","by","0","is","not","defined",".","Thus",",","if","any","of","the","terms","in","the","WoE","equation","are","0","for","a","given","category",",","the","encoder","will","return","an","error",".","If","this","happens",",","try","grouping","less","frequent","categories",".","More","details","in","the",":","ref",":","`","User","Guide","<","woe_encoder",">","`",".","Parameters","--","--","--","--","--","{","variables","}","{","ignore_format","}","{","unseen","}","Attributes","--","--","--","--","--","encoder_dict_",":","Dictionary","with","the","WoE","per","variable",".","{","variables_","}","{","feature_names_in_","}","{","n_features_in_","}","Methods","--","--","--","-","fit",":","Learn","the","WoE","per","category",",","per","variable",".","{","transform","}","{","fit_transform","}","{","inverse_transform","}","Notes","--","--","-","For","details","on","the","calculation","of","the","weight","of","evidence","visit",":","https",":","\/\/www.listendata.com\/2015\/03\/weight-of-evidence-woe-and-information.html","NAN","are","introduced","when","encoding","categories","that","were","not","present","in","the","training","dataset",".","If","this","happens",",","try","grouping","infrequent","categories","using","the","RareLabelEncoder","(",")",".","There","is","a","similar","implementation","in","the","the","open-source","package","`","Category","encoders","<","https",":","\/\/contrib.scikit-learn.org\/category_encoders\/",">","`","_","See","Also","--","--","--","--","feature_engine.encoding.RareLabelEncoder","feature_engine.discretisation","category_encoders.woe.WOEEncoder","Examples","--","--","--","--",">",">",">","import","pandas","as","pd",">",">",">","from","feature_engine.encoding","import","WoEEncoder",">",">",">","X","=","pd.DataFrame","(","dict","(","x1","=","[","1,2,3,4,5","]",",","x2","=","[","``","b","''",",","``","b","''",",","``","b","''",",","``","a","''",",","``","a","''","]",")",")",">",">",">","y","=","pd.Series","(","[","0,1,1,1,0","]",")",">",">",">","woe","=","WoEEncoder","(",")",">",">",">","woe.fit","(","X",",","y",")",">",">",">","woe.transform","(","X",")","x1","x2","0","1","0.287682","1","2","0.287682","2","3","0.287682","3","4","-0.405465","4","5","-0.405465"]
code: def _more_tags(self):
      tags_dict = _return_tags()
      tags_dict["variables"] = "categorical"
      tags_dict["requires_y"] = True
      # in the current format, the tests are performed using continuous np.arrays
      # this means that when we encode some of the values, the denominator is 0
      # and this the transformer raises an error, and the test fails.
      # For this reason, most sklearn transformers will fail. And it has nothing to
      # do with the class not being compatible, it is just that the inputs passed
      # are not suitable
      tags_dict["_skip_test"] = True
      return tags_dict
  
imports: from typing import List, Union
  import numpy
  import pandas
  from feature_engine._docstrings.fit_attributes import _feature_names_in_docstring, _n_features_in_docstring, _variables_attribute_docstring
  from feature_engine._docstrings.init_parameters import _ignore_format_docstring, _unseen_docstring, _variables_categorical_docstring
  from feature_engine._docstrings.methods import _fit_transform_docstring, _inverse_transform_docstring, _transform_encoders_docstring
  from feature_engine._docstrings.substitute import Substitution
  from feature_engine.dataframe_checks import check_X_y
  from feature_engine.encoding._helper_functions import check_parameter_unseen
  from feature_engine.encoding.base_encoder import CategoricalInitMixin, CategoricalMethodsMixin
  from feature_engine.tags import _return_tags
label_desc: Use image node_id 3 for calling the WoEEncoder obj's underlying member method code with example usage: obj._more_tags() and returns: tags_dict