0% found this document useful (0 votes)
11 views13 pages

Japneet's File

Uploaded by

gurig0049
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views13 pages

Japneet's File

Uploaded by

gurig0049
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 13

Notes

This is to certify that japneet singh of class XII


has completed his project file of INFORMATICS
PRACTICES guidance of MS.VANDANA
TRIPATHI for the academic year 2023-2024. The
certified student has been dedicated throughout
his research and completed his work before the
given deadline without missing any important
details from the project. It is also certified that
this project is the individual work of the student
and can be submitted for evaluation.

TEACHER’S
SIGNATURE
INTRODUCTION
TASK
CODING
OUTPUT
BIBLIOGRAPHY
Add Team of lead of the call
centre, has got the below
mentioned attribute of their
teams performance, he/she need
to answer the below mentioned
queries to management in
addition this the he/she need to
make the group of charts to
form a dashboard for top
manage on performance of
his/her department
a subheading
LANGUAGE :-PYTHON
DATA BASE:-PYTHON
PANDAS(DATA FRAME, SERIES )
CONNECTIVITY :-READING
THROUGH CSV FILE / EXCEL FILE
IDE USED :- CANOPY
Make a function to accept the week number
and share the below mentioned values of
respective week number.
Make a function to accept
agent name and get the
below mentioned values of
respective agent
Add a import pandas as pd
def weekinfor(n,df):
if n==1:
dfweek=df[(df['ndate']>='2016-01-01') & (df['ndate']<='2016-
01-07')]
elif n==2:
dfweek= df[(df['ndate']>='2016-01-08') & (df['ndate']<='2016-
01-14')]
elif n==3:
dfweek= df[(df['ndate']>='2016-01-15') & (df['ndate']<='2016-
01-21')]
elif n==4:
dfweek= df[(df['ndate']>='2016-01-22') & (df['ndate']<='2016-
01-28')]
elif n==5:
dfweek= df[(df['ndate']>='2016-01-29') & (df['ndate']<='2016-
01-31')]
else:
print("invalid week")

total_calls=dfweek['Call Id'].count()
print('Total calls of the week is :-', total_calls)
# Answerd call
call_ans=dfweek[dfweek['Answered']=='Y']['Call Id'].count()
print("total call answered :-",call_ans)
# Average speed of answer
avg_speed_ans=dfweek['Speed of Answer'].mean()
print("The average speed of answer is :- ", avg_speed_ans)
abandan_calls= total_calls-call_ans
print("Total abandon calls :- ", abandan_calls)
overall_satisfaction=dfweek['Satisfaction rating'].mean()
Add a print("over all satisfaction:- ", overall_satisfaction)
# calculating calls of less the 180 second
h=0
m=0
s=0
total=0
l=[]
sind=dfweek.index
for x in sind:
h=int(df['nAvgTalkDuration'][x].strftime("%H"))
h=h*60*60
m=int(df['nAvgTalkDuration'][x].strftime("%M"))
m=m*60
s=int(df['nAvgTalkDuration'][x].strftime("%S"))
total=h+m+s
l.append(int(total))
dfweek.insert(10,'timeinsec',l)

callless180=dfweek[dfweek['timeinsec']<180]['Call Id'].count()
print("total calls less then 180 seconds :- ",callless180)
print(" % of call less then 180 sec " , callless180/len(sind)*100)

# satisfaction rating less then 3


print("satisfaction rating less then 3 :- ",dfweek[dfweek['Satisfaction rating']<3]['Call
Id'].count())

def getagentdetail(name,df):
dfname=df[df['Agent']==name]
print(dfname)
total_calls=dfname['Call Id'].count()
print("total call by ", name, total_calls)
call_ans=dfname[dfname['Answered']=='Y']['Call Id'].count()
print("total call answered :-",call_ans)
avg_speed_ans=dfname['Speed of Answer'].mean()
print("The average speed of answer is :- ", avg_speed_ans)
call_resolved=dfname[dfname['Resolved']=='Y']['Call Id'].count()
print("call resolved :- ", call_resolved)
call_not_resolved=dfname[dfname['Resolved']=='N']['Call
Id'].count()
print("call not resolved ", call_not_resolved)
print("% of call resolved ", call_resolved/total_calls*100)

df=pd.read_csv(r"D:\Call Center\Call_Centre.csv")
dfdate=pd.to_datetime(df['Date'])
dfdate=pd.DataFrame(dfdate,columns=['Date'])
df.insert(1,'ndate',dfdate['Date'])
df['AvgTalkDuration'].fillna('00:00:00',inplace=True)
dfdate=pd.to_datetime(df['AvgTalkDuration'])
dfdate=pd.DataFrame(dfdate,columns=['AvgTalkDuration'])
df.insert(9,'nAvgTalkDuration',dfdate['AvgTalkDuration'])

# removing unnessary column


df.drop('Unnamed: 10',1,inplace=True)
df.drop('Unnamed: 9',1,inplace=True)

n=int(input("enter week number ( 1 to 5)"))

weekinfor(n,df)

getagentdetail('Diane',df)
enter week number ( 1 to 5)1
Total calls of the week is :- 398
total call answered :- 324
The average speed of answer is :- 69.75617283950618
Total abandon calls :- 74
over all satisfaction:- 3.441358024691358
total calls less then 180 seconds :- 202
% of call less then 180 sec 50.753768844221106
satisfaction rating less then 3 :- 63
Call Id ndate Date Agent Department Answered Resolved \
0 ID0001 2016-01-01 1-Jan-16 Diane Washing Machine Y Y
6 ID0007 2016-01-01 1-Jan-16 Diane Toaster Y Y
7 ID0008 2016-01-01 1-Jan-16 Diane Toaster Y Y
24 ID0025 2016-01-01 1-Jan-16 Diane Television Y Y
32 ID0033 2016-01-01 1-Jan-16 Diane Air Conditioner Y Y
... ... ... ... ... ... ... ...
1736 ID1737 2016-01-31 31-Jan-16 Diane Toaster Y Y
1752 ID1753 2016-01-31 31-Jan-16 Diane Air Conditioner Y Y
1753 ID1754 2016-01-31 31-Jan-16 Diane Television Y Y
1755 ID1756 2016-01-31 31-Jan-16 Diane Television Y Y
1769 ID1770 2016-01-31 31-Jan-16 Diane Toaster Y Y

Speed of Answer AvgTalkDuration nAvgTalkDuration Satisfaction rating


0 109.0 0:02:23 2024-01-25 00:02:23 3.0
6 24.0 0:03:40 2024-01-25 00:03:40 2.0
7 22.0 0:00:38 2024-01-25 00:00:38 4.0
24 97.0 0:04:09 2024-01-25 00:04:09 3.0
32 57.0 0:06:49 2024-01-25 00:06:49 3.0
... ... ... ... ...
1736 37.0 0:06:57 2024-01-25 00:06:57 4.0
1752 113.0 0:02:32 2024-01-25 00:02:32 1.0
1753 93.0 0:02:19 2024-01-25 00:02:19 4.0
1755 92.0 0:02:28 2024-01-25 00:02:28 3.0
1769 78.0 0:01:03 2024-01-25 00:01:03 4.0

[222 rows x 11 columns]


total call by Diane 222
total call answered :- 185
The average speed of answer is :- 63.935135135135134
call resolved :- 168
call not resolved 54
% of call resolved 75.67567567567568
PREETI ARORA 12TH BOOK
NCERT
PYTHON FOR CS IP.COM
YT- MAGNET BRAINS

You might also like