class_docstr: The XGBoost classifier.
  
  Reference: http://xgboost.readthedocs.io/en/latest/model.html
  
  Parameters:
  -----------
  n_estimators: int
      The number of classification trees that are used.
  learning_rate: float
      The step length that will be taken when following the negative gradient during
      training.
  min_samples_split: int
      The minimum number of samples needed to make a split when building a tree.
  min_impurity: float
      The minimum impurity required to split the tree further. 
  max_depth: int
      The maximum depth of a tree.
class_docstr_tok: ["The","XGBoost","classifier",".","Reference",":","http",":","\/\/xgboost.readthedocs.io\/en\/latest\/model.html","Parameters",":","--","--","--","--","--","-","n_estimators",":","int","The","number","of","classification","trees","that","are","used",".","learning_rate",":","float","The","step","length","that","will","be","taken","when","following","the","negative","gradient","during","training",".","min_samples_split",":","int","The","minimum","number","of","samples","needed","to","make","a","split","when","building","a","tree",".","min_impurity",":","float","The","minimum","impurity","required","to","split","the","tree","further",".","max_depth",":","int","The","maximum","depth","of","a","tree","."]
code: def __init__(
      self,
      n_estimators=200,
      learning_rate=0.001,
      min_samples_split=2,
      min_impurity=1e-7,
      max_depth=2,
  ):
      self.n_estimators = n_estimators  # Number of trees
      self.learning_rate = learning_rate  # Step size for weight update
      self.min_samples_split = (
          min_samples_split  # The minimum n of sampels to justify split
      )
      self.min_impurity = (
          min_impurity  # Minimum variance reduction to continue
      )
      self.max_depth = max_depth  # Maximum depth for tree
  
      self.bar = progressbar.ProgressBar(widgets=bar_widgets)
  
      # Log loss for classification
      self.loss = LogisticLoss()
  
      # Initialize regression trees
      self.trees = []
      for _ in range(n_estimators):
          tree = XGBoostRegressionTree(
              min_samples_split=self.min_samples_split,
              min_impurity=min_impurity,
              max_depth=self.max_depth,
              loss=self.loss,
          )
  
          self.trees.append(tree)
  
file_path: ML-From-Scratch/mlfromscratch/supervised_learning/xgboost.py
imports: from __future__ import division, print_function
  import numpy
  import progressbar
  from mlfromscratch.utils import train_test_split, standardize, to_categorical, normalize
  from mlfromscratch.utils import mean_squared_error, accuracy_score
  from mlfromscratch.supervised_learning import XGBoostRegressionTree
  from mlfromscratch.deep_learning.activation_functions import Sigmoid
  from mlfromscratch.utils.misc import bar_widgets
  from mlfromscratch.utils import Plot
label_desc: Use image node_id 1 to create a new XGBoost object from inherited base classes: object with example: obj = XGBoost(n_estimators, learning_rate, min_samples_split, min_impurity, max_depth)