title: is sklearn.tree.DecisionTreeClassifier stuck at predicting most frequent category?
body: <p>Below is the details of my code that I think is relevant to my question. </p>
  
  <ol>
  <li>I created the target binary variable PP like this, with PP's distribution attached. As you see, <code>False/0</code> ~66% and <code>True/1</code> =34%</li>
  </ol>
  
  <pre><code>pandas_df['PP'] =(pandas_df['DET'].fillna(0) &lt;1).astype('str')  
  
  False    48114
  True     25089
  Name: FP, dtype: int64
  </code></pre>
  
  <ol start="2">
  <li>Below is the model code. The goal is predict the probability of TRUE, as most models do</li>
  </ol>
  
  <pre><code>X= pandas_df[predictors]
  y2= pandas_df.PP
  tree_clf =DecisionTreeClassifier(max_depth=3, random_state=42,min_samples_leaf=500)
  tree_clf.fit(X, y2)
  </code></pre>
  
  <ol start="3">
  <li>Then I visualize the model as below (I left blank feature_names intentionally since it is long)</li>
  </ol>
  
  <pre><code> dot_data2 =tree.export_graphviz(tree_clf,out_file=None,feature_names=(),....                                           
  
   pydot_graph = pydotplus.graph_from_dot_data(dot_data2)
   pydot_graph.set_size('"0.5,0.5!"')
   pydot_graph.write_png('resized_tree.png')
   DTgraph=graphviz.Source(dot_data2)
   DTgraph  
  </code></pre>
  
  <p>The code is error free. Graph appears meaningful. </p>
  
  <p>BUT: in each leaf/node displayed, it says <code>Class=False</code>. I ran a test by creating another variable PP2 to just flip PP 0 to 1 and 1 to 0. It then says Class=True because in PP2 it is True that is 66%.</p>
  
  <p>I can live with PP2, twist my head a bit to understand it right. But nightmare to present the tree to business audience. I read through sklearn documentation and user guide. Did not find ways to force it to predict probability of TRUE. Am I misreading Class=False? </p>