"""
**Q1**

From 100 people, 30 of them have blood type A, 38 have blood type O, 24 have blood type B, 8 have blood type AB.
We want to visualize this data here:
"""
import numpy as np
import pandas as pd
import matplotlib.pyplot as plt
%matplotlib inline
"""
Let's create a bar plot first:
"""
blood_type = ['A','O','B','AB']
frequency = [30, 38, 24, 8]
fig= plt.figure(figsize=(5,3), dpi=100)
ax = fig.add_axes([0, 0, 0.8, 0.8])
ax.bar(blood_type, frequency, color='#f5b402')
"""
Now let's see it on a pie chart:
"""
fig= plt.figure(figsize=(5,5), dpi=100)
ax = fig.add_axes([0, 0, 0.8, 0.8])
colors = ['gold', 'yellowgreen', 'lightcoral', 'lightskyblue']
ax.pie(frequency, labels = blood_type, colors=colors, autopct='%1.1f%%')
"""
**Q2**

Let's drow a scatter plot for the data given below:
"""
x= [5,7,8,7,2,17,2,9,4,11,12,9,6]
y= [99,86,87,88,111,86,103,87,94,78,77,85,86]
fig= plt.figure(figsize=(5,3), dpi=100)
ax = fig.add_axes([0, 0, 0.8, 0.8])
plt.scatter(x, y, alpha=0.5)
ax.set_title('scatter plot')
ax.set_xlabel('X')
ax.set_ylabel('Y')
"""
**Q3**

Let's draw a graph from a normal distribution, with 300 point, mu=170 and sigma=10:
"""
normal = np.random.normal(170, 10, 300)
fig= plt.figure(figsize=(5,3), dpi=100)
ax = fig.add_axes([0, 0, 0.8, 0.8])
plt.hist(x=normal, bins='auto', color='#0504aa', alpha=0.7, rwidth=0.85)
plt.xlabel('Value')
plt.ylabel('Frequency')
plt.title( 'Histogram')