-2

I am using yellowbrick to plot the AUCROC. I want to remove the title from the plot, to make it empty without the plot title.

model = classifier
visualizer = ROCAUC(model, encoder={0: 'class' , 1: 'class2'}
visualizer.fit(X_train, y_train)        
visualizer.score(X_test, y_test)       
visualizer.show()   

                
user
  • 5
  • 3
  • Welcome to Stack Overflow! You seem to be asking two questions here, please post each one separately so we can answer them individually. – Anonymous Jun 14 '21 at 21:28
  • 2
    Please see [How to ask a good question](https://stackoverflow.com/help/how-to-ask). Always provide a complete [mre] with **code, data, errors, current output, and expected output**, as **[formatted text](https://stackoverflow.com/help/formatting)**. If relevant, only plot images are okay. Provide data with [How to provide a reproducible copy of your DataFrame using `df.head(30).to_clipboard(sep=',')`](https://stackoverflow.com/q/52413246/7758804), then **[edit] your question**, and paste the clipboard into a code block. – Trenton McKinney Jun 14 '21 at 21:30
  • first you could check in documentation if it has option for this. Next you can check source code if you could create own function without title. – furas Jun 14 '21 at 23:40
  • yellowbrick documentation [How can I change the title of a Yellowbrick plot?](https://www.scikit-yb.org/en/latest/faq.html?highlight=title#how-can-i-change-the-title-of-a-yellowbrick-plot) - and you could try with empty string `title=""` – furas Jun 14 '21 at 23:42

1 Answers1

0

yellowbrick documentation How can I change the title of a Yellowbrick plot?

If I use single space in title=" " then I get plot without title.
It doesn't work with empty string title="".


Minimal working example

from yellowbrick.classifier import ROCAUC
from sklearn.linear_model import RidgeClassifier

# single space in title
visualizer = ROCAUC(RidgeClassifier(), title=" ")
visualizer.show()

enter image description here

furas
  • 134,197
  • 12
  • 106
  • 148