Matplotlib Tutorial | Create Scatter Plot ,Colorbar (Tutorial 4)

Pubblicato il: 13 aprile 2020
sul canale di: Manav Rao
229
9

Hey Everyone In last We have seen Pie Chart in Today's Video We are going To learn Scatter Plot. Scatter Plot is Mainly use to understand the Correlation Between Two or More variables .
In this Video We will Learn How to set Color Bar to Our Scatter Plot and Also We Will Learn How to Customize Our Scatter Plot .
If You Have Any Question About Scatter Plot Ask Me In Comment Section.

Code: -
===========================================================
from matplotlib import pyplot as plt

x=[1,5,2,6,8,5,3,5,9,3,5,3,7]
y=[9,3,4,6,7,8,9,7,5,4,6,7,4]

color=[1,2,5,7,5,2,4,6,7,8,6,4,6]

plt.scatter(x,y,s=100,marker="o",c=color,edgecolors="Black",linewidths=0.5,alpha=1,label="Happy")
cbar=plt.colorbar()
cbar.set_label("Happiness")
plt.legend()
plt.show()
============================================================



Data That I used in This Video : -
x=[1,5,2,6,8,5,3,5,9,3,5,3,7]
y=[9,3,4,6,7,8,9,7,5,4,6,7,4]
color=[1,2,5,7,5,2,4,6,7,8,6,4,6]


In questa pagina del sito puoi guardare il video online Matplotlib Tutorial | Create Scatter Plot ,Colorbar (Tutorial 4) della durata di ore minuti seconda in buona qualità , che l'utente ha caricato Manav Rao 13 aprile 2020, condividi il link con amici e conoscenti, su youtube questo video è già stato visto 229 volte e gli è piaciuto 9 spettatori. Buona visione!