Perfect Plots: Bubble Plot

November 7, 2019 admin 0

In [1]: import pandas as pd import matplotlib.pyplot as plt import numpy as np Autos Source of data: https://datahub.io/machine-learning/autos In [2]: df2= pd.read_csv(‘c:/1/autos.csv’) df2.head() Out[2]: Unnamed: […]

Dendrogram and clustering 3d

October 25, 2019 admin 0

In [1]: import scipy.cluster.hierarchy as shc import pandas as pd import matplotlib.pyplot as plt # Import Data df = pd.read_csv(‘c:/1/USArrests.csv’) USArrests Source of data: https://www.kaggle.com/deepakg/usarrests […]

Perfect Plots: Calendarplot

October 24, 2019 admin 0

In [1]: import matplotlib as mpl import calmap import pandas as pd import matplotlib.pyplot as plt yahoo In [2]: df = pd.read_csv(‘c:/1/yahoo.txt’, parse_dates=[‘date’]) df.set_index(‘date’, inplace=True) df.head(3) […]

Perfect Plots: H_line plot

October 22, 2019 admin 0

In [1]: import numpy as np import pandas as pd import seaborn as sns from sklearn.preprocessing import LabelEncoder import matplotlib.pylab as plt from pylab import […]

Perfect Plots: Waffle plot

October 22, 2019 admin 0

https://www.machinelearningplus.com/plots/top-50-matplotlib-visualizations-the-master-plots-python/ pip install pywaffle In [1]: from pywaffle import Waffle import squarify import pandas as pd import matplotlib.pyplot as plt Car market analysis Source of data: […]

Perfect Plots: Slope Chart

October 22, 2019 admin 0

In [1]: import pandas as pd import matplotlib.pyplot as plt import matplotlib.lines as mlines import numpy as np # Import Data df = pd.read_csv(‘c:/2/gdppercap.txt’) df […]

Perfect Plot: Treemap

October 22, 2019 admin 0

An old Chinese proverb says: one picture says more than one thousands words. One good plot can rescue entire presentation. One poor picture can drown […]

Perfect Plots: Categorical Plot

October 22, 2019 admin 0

Analysis of the categorical results. In [1]: import pandas as pd import matplotlib.pyplot as plt import seaborn as sns Titanic disaster Analysis of the categorical results. […]

Perfect Plots: Pie Plot

October 17, 2019 admin 0

An old Chinese proverb says: one picture says more than one thousands words. One good plot can rescue entire presentation. One poor picture can drown […]