Amazing technological breakthrough possible @S-Logix pro@slogix.in

Office Address

  • #5, First Floor, 4th Street Dr. Subbarayan Nagar Kodambakkam, Chennai-600 024 Landmark : Samiyar Madam
  • pro@slogix.in
  • +91- 81240 01111

Social List

How to create density plot using seaborn library in python?

Description

To create density plot for X variable using python.

Process

   Import seaborn library.

   Read the data set.

   Put the density plot.

Sample Code

#import library functions

import seaborn as sns

import pandas as pd

#Read the data set

data=pd.read_csv(‘/home/soft27/soft27/

Sathish/Pythonfiles/Employee.csv’)

#create data frame

df=pd.DataFrame(data)

print(“Data from the CSV file is\n”,df)

#density plot

sns.distplot(df[‘salary’], hist = False, kde = True,

kde_kws = {‘linewidth’: 3},label = df[‘name’])

Screenshots
create density plot using seaborn library in python
Read the data set