title: AdaBoostClassifier and the 'SAMME.R’ Algorithm
body: <p>It takes a while to get to the actual question, so please bear with me. <a href="https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.AdaBoostClassifier.html" rel="nofollow noreferrer">The AdaBoost documentation</a> states that it " is a meta-estimator that begins by fitting a classifier on the original dataset and then fits additional copies of the classifier on the same dataset but where the weights of incorrectly classified instances are adjusted". To do that, one of the required paramenters is <code>base_estimator</code>. For the <code>base_estimator</code> to be useable with <code>AdaBoostClassifer</code>, "support for sample weighting is required". </p>
  
  <p>So my first issue was - which classifiers provide support for sample weighting? I did some research, and, fortunately, <a href="https://stackoverflow.com/a/18323552/9448090">someone smarter than me had the answer</a>.  Somewhat updated, it works thus: by running</p>
  
  <pre><code>from sklearn.utils.testing import all_estimators 
  
  print(all_estimators(type_filter='classifier'))
  </code></pre>
  
  <p>you get a list of all classifiers (turns out there are 31 of them!). Then, if you run</p>
  
  <pre><code>import inspect
  
  for name, clf in all_estimators(type_filter='classifier'):
      if 'sample_weight' in inspect.getfullargspec(clf().fit)[0]:
          print(name)
  </code></pre>
  
  <p>you can get the list of all classifiers which provide support for sample weighting (21 of them, for the curious). </p>
  
  <p>So far so good. But now we have to deal with another  <code>AdaBoostClassifer</code> parameter, namely <code>algorithm</code>. You have two options: <code>{‘SAMME’, ‘SAMME.R’}, optional (default=’SAMME.R’)</code>. We're told that to "use the SAMME.R real boosting algorithm  <code>base_estimator</code> must support calculation of class probabilities". And this is where I got stuck. Searching online, I can only find two classifiers used with ‘SAMME.R’ as an argument for <code>algorithm</code>: <code>DecisionTreeClassifier</code> (which is the default) and <code>RandomForestClassifier</code>.</p>
  
  <p>So here's the question - which other classifiers from the 21 which are compatible with <code>AdaBoostClassifer</code> offer support for the calculation of class probablities?</p>
  
  <p>Thanks.</p>