"""
# IRIS SPECIES 
"""
"""
# 
"""
"""
# TASK : 
#         To Predict the species of the iris flower.
"""
"""
Importing necessary libraries:

"""
import numpy as np # linear algebra
import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)
import matplotlib.pyplot as plt
import seaborn as sns
import scipy as sp
import os
import graphviz 
import preprocessing 

"""
# IMPORTING THE DATA
"""
dataset = pd.read_csv('../input/iris/Iris.csv')
"""
# DISPLAYING THE TOP 5 RECORDS USING HEAD
"""
dataset.head()
dataset.info()
dataset.shape   # displaying the number of rows and columns
dataset.columns   # displaying all the columns
dataset.count()  #count the values
dataset.describe()  #describe the data
dataset.isnull().sum()
dataset.value_counts
iris=dataset
"""
# VISUALIZATION USING DIFFERENT PLOTS
"""
"""
# SCATTER PLOT:
"""
# We will make a scatterplot of two of the four Iris features 


iris.plot(kind="scatter", x="SepalLengthCm", y= "SepalWidthCm")
"""
# JOINT PLOT:
"""
## we can do it also with the seaborn library

## A seaborn jointplot shows bivariate scatterplots and univariate histograms in the 
# same figure

sns.jointplot( data=iris,x="SepalLengthCm", y="SepalWidthCm", size=5)
"""
# DENSITY PLOT : KDE
"""
## we can do it also with the seaborn library

## A seaborn kdeplot shows density scatterplots and univariate histograms in the 
# same figure

sns.kdeplot(data= iris, x="SepalLengthCm", y="SepalWidthCm", size=5)
"""
# FACET GRID:
"""
sns.FacetGrid(iris, hue="Species", palette="husl",size=5) \
   .map(plt.scatter, "SepalLengthCm", "SepalWidthCm") \
   .add_legend()
"""
# BOXPLOT
"""
sns.boxplot(x="Species", y="PetalLengthCm", data=iris)
"""
# VIOLIN PLOT:
"""
sns.violinplot(data=iris, x="Species", y="PetalWidthCm",
                palette="rocket")
"""
# PAIR PLOT:
"""
sns.pairplot(iris.drop("Id", axis=1), 
             hue ="Species",palette= "husl", size=3) 
 
dataset.tail()
"""
# HEATMAP
"""
plt.figure(figsize=(12,8)) 
sns.heatmap(dataset.corr(), annot=True, cmap='Dark2_r', linewidths = 2)
plt.show()
plt.figure(figsize=(25,15))

plt.subplot(2,2,1)
sns.histplot(dataset['SepalLengthCm'], color = 'red', kde = True).set_title('SepalLengthCm Interval and Counts')

plt.subplot(2,2,2)
sns.histplot(dataset['SepalWidthCm'], color = 'green', kde = True).set_title('SepalWidthCm Interval and Counts')

plt.subplot(2,2,3)
sns.histplot(dataset['PetalLengthCm'], kde = True, color = 'blue').set_title('PetalLengthCm Interval and Counts')

plt.subplot(2,2,4)
sns.histplot(dataset['PetalWidthCm'], kde = True, color = 'black').set_title('PetalWidthCm Interval and Counts')
"""
# DATA VISUALIZATION USING BAR
"""
plt.figure(figsize=(20,15))
plt.subplot(2,2,1)
sns.barplot(x = 'Species', y = 'SepalLengthCm', data = dataset, palette="cubehelix")
plt.subplot(2,2,2)
sns.barplot(x = 'Species', y = 'SepalWidthCm', data = dataset, palette="Oranges")
plt.subplot(2,2,3)
sns.barplot(x = 'Species', y = 'PetalLengthCm', data = dataset, palette="Oranges")
plt.subplot(2,2,4)
sns.barplot(x = 'Species', y = 'PetalWidthCm', data = dataset, palette="cubehelix")
plt.figure(figsize=(20,15))
plt.subplot(2,2,1)
sns.distplot(dataset['SepalLengthCm'], color="red").set_title('SepalLength Interval')
plt.subplot(2,2,2)
sns.distplot(dataset['SepalWidthCm'], color="green").set_title('SepalWidth Interval')
plt.subplot(2,2,3)
sns.distplot(dataset['PetalLengthCm'], color="blue").set_title('PetalLength Interval')
plt.subplot(2,2,4)
sns.distplot(dataset['PetalWidthCm'], color="black").set_title('PetalWidth Interval')
"""
# Conclusion: 

In this notebook, I examined Iris Species Dataset. Firstly, I made Exploratory Data Analysis, then I Visualize the data to Predict the species of the iris flower using different plots .

If you have questions, please comment them. I will try to explain if you don't understand.
If you liked this notebook, please let me know :)
Thank you for your time. Cheers!!
"""