watex.view.QuickPlot.discussingfeatures#
- QuickPlot.discussingfeatures(features, *, map_kws=None, map_func=None, **sns_kws)[source]#
Provides the features names at least 04 and discuss with their distribution.
This method maps a dataset onto multiple axes arrayed in a grid of rows and columns that correspond to levels of features in the dataset. The plots produced are often called “lattice”, “trellis”, or ‘small-multiple’ graphics.
- Parameters
features (list) –
List of features for discussing. The number of recommended features for better analysis is four (04) classified as below:
features_disposal = [‘x’, ‘y’, ‘col’, ‘target|hue’]
- where:
x is the features hold to the x-axis, default is``ohmS``
y is the feature located on y_xis, default is
sficol is the feature on column subset, *default` is
coltarget or hue for targetted examples, default is
flow
If 03 features are given, the latter is considered as a target
- map_kws:dict, optional
Extra keyword arguments for mapping plot.
- func_map: callable, Optional
callable object, is a plot style function. Can be a ‘matplotlib-pyplot’ function like
plt.scatteror ‘seaborn-scatterplot’ likesns.scatterplot. The default issns.scatterplot.- sns_kwargs: dict, optional
kwywords arguments to control what visual semantics are used to identify the different subsets. For more details, please consult <http://seaborn.pydata.org/generated/seaborn.FacetGrid.html>.
- data: str or pd.core.DataFrame
Path -like object or Dataframe. Long-form (tidy) dataset for plotting. Each column should correspond to a variable, and each row should correspond to an observation. If data is given as path-like object,`QuickPlot` reads and sanitizes data before plotting. Be aware in this case to provide the target name and possible the classes for data inspection. Both str or dataframe need to provide the name of target.
- Returns
Returns
selffor easy method chaining.- Return type
QuickPlotinstance
Notes
The argument for data must be passed to fit method. data parameter is not allowed in other QuickPlot method. The description of the parameter data is to give a synopsis of the kind of data the plot expected. An error will raise if force to pass data argument as a keyword arguments.
Examples
>>> from watex.view.plot import QuickPlot >>> from watex.datasets import load_bagoue >>> data = load_bagoue ().frame >>> qkObj = QuickPlot( leg_kws={'loc':'upper right'}, ... fig_title = '`sfi` vs`ohmS|`geol`', ... ) >>> qkObj.tname='flow' # target the DC-flow rate prediction dataset >>> qkObj.mapflow=True # to hold category FR0, FR1 etc.. >>> qkObj.fit(data) >>> sns_pkws={'aspect':2 , ... "height": 2, ... } >>> map_kws={'edgecolor':"w"} >>> qkObj.discussingfeatures(features =['ohmS', 'sfi','geol', 'flow'], ... map_kws=map_kws, **sns_pkws ... )