Showing posts with the label matplotlib

[FIXED] Plot histogram given pre-computed counts and bins

Issue I have some data x which I pass to numpy.histogram(x) to get the counts and bin edges. I th…

[FIXED] how to scatter plot in different colours and add a legend in python?

Issue from the following df I have extracted the desired rows **name** **event** **X** …

[FIXED] Issue with matplotlib when trying to show a png file from a URL

Issue I'm trying to open a png file using matplotlib to then add further layers of clusters/gra…

[FIXED] Plotting Threshold (precision_recall curve) matplotlib/sklearn.metrics

Issue I am trying to plot the thresholds for my precision/recall curve. I am just using the MNSIT d…

[FIXED] Is it possible that Precision-Recall curve or a ROC curve is a horizontal line?

Issue I am working on a binary classification task on imbalanced data. Since the accuracy is not …

[FIXED] add precision-recall curves to plot using a function

Issue I have a dataframe with precision and recall for many classifiers, each one ran with 4 differ…

[FIXED] How to plot precision and recall of multiclass classifier?

Issue I'm using scikit learn, and I want to plot the precision and recall curves. the classifie…

[FIXED] How label to the data (not the axes) of the plot of a confusion matrix that displays True Positive, False Positive, False Negative and True Negative

Issue I am trying to label the plot of my confusion matrix. The first image below is what my plot c…

[FIXED] How to find the 'peak' of a polynomial regression line in Matplotlib

Issue Is it possible to find the peak (vertex?) values (x,y) of a polynomial regression line that w…

[FIXED] Jupyter Notebook: interactive plot with widgets

Issue I am trying to generate an interactive plot that depends on widgets. The problem I have is th…

[FIXED] How do I fix plt.subplots to bring the plots closer together?

Issue I am plotting 27 maps, or 9 rows and 3 columns. I am using plt.subplots to plot them, but I a…

[FIXED] Color problem while trying to plot KMeans clusters

Issue I am trying to plot my data with a colours related to the clusters as shown below: src="…

[FIXED] Plot big dataset clusters in python

Issue So basically I'm kind of new to sklearn and ML with python in general. I'm used to Ra…

[FIXED] How to plot the cluster's centroids using seaborn

Issue Basically, I want to plot like this: src="https://i.stack.imgur.com/I8Sdd.png" alt…

[FIXED] Precise type annotating array (numpy.ndarray) of matplotlib Axes from plt.subplots()

Issue I wanted to have no errors while using VSCode Pylance type checker. How to type the axs cor…

[FIXED] Is it possible to set the norm parameter in df.plot.scatter?

Issue I prefer df.plot.scatter() rather than plt.scatter() when doing data exploration. However I…

[FIXED] How to increase/reduce the fontsize of x and y tick labels

Issue I seem to have a problem in figuring out how to increase or decrease the fontsize of both th…

[FIXED] How to relate QGraphicsScene position to position on a matplotlib plot axis

Issue I have a window which holds two plots, one is a 2D plot and the other is a selection of a cut…

[FIXED] AttributeError: 'FigureCanvasInterAgg' object has no attribute 'renderer'

Issue I am using Python 2.7 with the error stemming from the lines below: fig.canvas.draw() img =…

[FIXED] Stop the effect of %matplotlib notebook in Jupyter notebook

Issue I used the magic commands %matplotlib notebook at some ceil in my notebook to animate some s…