woodpecker/sklearn/decisiontree/decision_tree_structure.py
def show_leaf_samples_distribution(self, min_samples=0, max_samples=sys.maxsize, bins=10, figsize=None):
        """ Visualize distribution of leaves samples.

        :param bins: int
            Number of bins of histograms
        :param figsize: tuple of int
            The figure size to be displayed
        """

        self._calculate_leaf_nodes()
        if figsize:
            plt.figure(figsize=figsize)
        plt.hist([self.n_node_samples[i] for i in range(0, self.node_count) if
                  self.is_leaf[i] and self.n_node_samples[i] >= min_samples and self.n_node_samples[i] <= max_samples],
                 bins=bins)
        plt.xlabel("leaf sample", fontsize=20)
        plt.ylabel("leaf count", fontsize=20)
 Visualize distribution of leaves samples.

        :param bins: int
            Number of bins of histograms
        :param figsize: tuple of int
            The figure size to be displayed
        
Visualize distribution of leaves samples.
Visualize distribution of leaves samples .
def show_leaf_samples_distribution(self, min_samples=0, max_samples=sys.maxsize, bins=10, figsize=None):
        self._calculate_leaf_nodes()
        if figsize:
            plt.figure(figsize=figsize)
        plt.hist([self.n_node_samples[i] for i in range(0, self.node_count) if
                  self.is_leaf[i] and self.n_node_samples[i] >= min_samples and self.n_node_samples[i] <= max_samples],
                 bins=bins)
        plt.xlabel("leaf sample", fontsize=20)
        plt.ylabel("leaf count", fontsize=20)
def show_leaf_samples_distribution ( self , min_samples = 0 , max_samples = sys . maxsize , bins = 10 , figsize = None ) : self . _calculate_leaf_nodes ( ) if figsize : plt . figure ( figsize = figsize ) plt . hist ( [ self . n_node_samples [ i ] for i in range ( 0 , self . node_count ) if self . is_leaf [ i ] and self . n_node_samples [ i ] >= min_samples and self . n_node_samples [ i ] <= max_samples ] , bins = bins ) plt . xlabel ( "leaf sample" , fontsize = 20 ) plt . ylabel ( "leaf count" , fontsize = 20 )
Visualize distribution of leaves samples.
Visualize distribution of leaves samples .
""" Visualize distribution of leaves samples.

        :param bins: int
            Number of bins of histograms
        :param figsize: tuple of int
            The figure size to be displayed
        """
self
min_samples
max_samples
bins
int
Number of bins of histograms
int Number of bins of histograms
figsize
tuple of int
The figure size to be displayed
tuple of int The figure size to be displayed