Download as pdf or txt
Download as pdf or txt
You are on page 1of 26

[INFORMATICS PRACTICES PROJECT REPORT ]

[BOLLYWOOD BOX OFFICE]


FOR

AISSCE 2024 EXAMINATION

As a part of the Informatics Practices Course (065)

SUBMITTED BY: [ANUJOT SINGH] [Roll No 10]

Under the Guidance of: [MS ANNI KUMAR (PGT COMPUTER SCIENCE)]
BOLLYWOOD BOX OFFICE


CERTIFICATE
This is to certify that the Project entitled, Bollywood Box Office is a bonafide work done

by ANUJOT SINGH of class XII-E Session 2023-2024 in partial fulfillment of CBSE’s

AISSCE Examination 2024 and has been carried out under my direct supervision and

guidance. This report or a similar report on the topic has not been submitted for any other

examination and does not form a part of any other course undergone by the candidate.

Signature of Student Signature of Teacher

Name: Anujot Singh Name: Ms Anni Kumar

Board Roll No.: …………… Designation: PGT Computer Science

Place: Delhi Date:……………..

1
BOLLYWOOD BOX OFFICE


ACKNOWLEDGEMENT
In the accomplishment of this project successfully, many people have best owned upon me
their blessings and the heart pledged support, this time I am utilizing to thank all the people
who have been concerned with this project.

I would like to express my special thanks of gratitude to our principal Ms. Teena Solanki
teacher and Informatics Practices teacher Ms. Anni Kumar who gave me the golden
opportunity to do this wonderful project on the topic Bollywood Box Office, which also
helped me in doing a lot of Research and I came to know about so many new things I am
really thankful to them. The suggestions and instructions given by my IP teachers have
served as the major contributor towards the completion of the project.

I am over helmed in all humbleness and gratefulness to acknowledge my depth to all those
who have helped me to put these ideas, well above the level of simplicity and into
something concrete.

Any attempt at any level can 't be satisfactorily completed without the support and guidance
of my parents and friends.

I would like to thank my parents who helped me a lot in gathering different information,
collecting data and guiding me from time to time in making this project, despite of their
busy schedules, they gave me different ideas in making this project unique.

Lastly, I would like to thank my classmates who have helped me a lot.

Thanking you,

Anujot Singh

XII-E

2
BOLLYWOOD BOX OFFICE


INDEX
S.No. CONTENT PAGE NO.

1. Objective of the Project

2. Features of Python

3. Coding

4. Bibliography

3
BOLLYWOOD BOX OFFICE


OBJECTIVE OF THE PROJECT


The Bollywood Box Office is a project that is built using Python.
The project consists of Bollywood Box Office csv file, which provides
a well detailed data for programming and analyzing
The first section consists of questions on data frame created using
pandas library. Pandas library helps us to manipulate data. The second
section consists of graph plotted using matplotlib library, it helps us to
get a visualized form of data.

4
BOLLYWOOD BOX OFFICE


FEATURES OF PYTHON
Python is a widely used general-purpose, high level programming language. It was initially
designed by Guido van Rossum in 1991 and developed by Python Software Foundation. It
was mainly developed for emphasis on code readability, and its syntax allows programmers
to express concepts in fewer lines of code.

Python is a programming language that lets you work quickly and integrate systems more
efficiently.

Reason for increasing popularity

 Emphasis on code readability, shorter codes, ease of writing


 Programmers can express logical concepts in fewer lines of code in comparison to
languages such as C++ or Java.
 Python supports multiple programming paradigms, like object-oriented, imperative
and functional programming or procedural.
 There exists inbuilt functions for almost all of the frequently used concepts.
 Philosophy is “Simplicity is the best”.
LANGUAGE FEATURES

Interpreted There are no separate compilation and execution steps like C and C++.
Directly run the program from the source code. Internally, Python
converts the source code into an intermediate form called bytecodes
which is then translated into native language of specific computer to
run it. No need to worry about linking and loading with libraries, etc.

Platform Independent Python programs can be developed and executed on multiple


operating system platforms. Python can be used on Linux,
Windows, Macintosh, Solaris and many more. Free and
Open Source; Redistributable High-level Language. In Python,
no need to take care about low-level details such as managing the
memory used by the program.

Simple Closer to English language; Easy to Learn. More emphasis on the


solution to the problem rather than the syntax

5
BOLLYWOOD BOX OFFICE


Embeddable Python can be used within C/C++ program to give scripting capabilities
for the program’s users.

Robust: Exceptional handling features. Memory management techniques in


built.

Rich Library Support The Python Standard Library is vary vast. Known as the
“batteries included” philosophy of Python ;It can help do various
things involving regular expressions, documentation generation,
unit testing, threading, databases, web browsers, CGI, email,
XML, HTML, WAV files, cryptography, GUI and many more.
Besides the standard library, there are various other high-quality
libraries such as the Python Imaging Library which is an
amazingly simple image manipulation library.

6
BOLLYWOOD BOX OFFICE


CODING

# (Q1) Converting csv file to dataframe.

import pandas as pd

pb=pd.read_csv("bollywood_box_clean.csv", sep=",")

pb

7
BOLLYWOOD BOX OFFICE


# (Q2) Display first 50 elements of the Dataframe.

pb=pb.head(50)

pb

8
BOLLYWOOD BOX OFFICE


# (Q3) Display Movies with Drama Genre.

pb.loc[pb['movie_genre']=='Drama'

#(Q4) Display the release year and date of first ten movies of the dataframe.

pb.loc[0:10,['release_year','release_date']]

9
BOLLYWOOD BOX OFFICE


# (Q5) Show 0,1,3,5th row of the dataframe.

pb.loc[[0,1,3,5],:]

# (Q6) Display all values of movies where runtime > 140 and release month is February.

pb.loc[(pb['runtime']>140) & (pb['release_month']=='Feb')]

10
BOLLYWOOD BOX OFFICE


#(Q7) Display all values of movies directed by Anubhav Sinha

.pb.loc[pb['movie_director']=='Anubhav Sinha']

# (Q8) Display all details of movies which have firstweek earnings between 20 to 30 crore.

pb.loc[(pb['movie_firstweek']>=20) & (pb['movie_firstweek']<=30)]

11
BOLLYWOOD BOX OFFICE


# (Q9) Delete the column Banner and it's values

.del pb['banner']

pb

# (Q10) Display the movie name and it's genre of 15-20 movies.
pb.loc[15:20,['movie_name', 'movie_genre']]

12
BOLLYWOOD BOX OFFICE


# (Q11) Display the last 40 elements of the dataframe.

pb=pb.tail(40)

pb

13
BOLLYWOOD BOX OFFICE


# (Q12) Display all values of movies where release day > 10th day of the month and
total earnings > 100 cr.

pb.loc[(pb['movie_total']>100) & (pb['release_day']>10),:]

14
BOLLYWOOD BOX OFFICE


# (Q13) Delete the 45th and 46th row from the dataframe.

pb.drop([45,46],axis=0)

15
BOLLYWOOD BOX OFFICE


# (Q14) Display all details of movies released before 2020 that had earned more than
100 cr.

pb.loc[(pb['release_year']<=2020) & (pb['movie_total']>=100)]

16
BOLLYWOOD BOX OFFICE


# (Q15) WAP to create a line plot for the column movie_opening wrt movie_name of
the dataframe.

import matplotlib.pyplot as plt

pb=pb.tail(10)

x=pb.loc[:,'movie_name']

y=pb.loc[:,'movie_opening']

plt.plot(x,y,marker='P',markersize=10,color='red',

linewidth=2, linestyle='dashdot')

plt.grid(True)

plt.xlabel("Movie weekend----->")

plt.ylabel("Movie Opening----->")

plt.title("Movie Earnings")

plt.show()

17
BOLLYWOOD BOX OFFICE


# (Q16) WAP to create a line plot for the columns (movie_total and
movie_total_worldwide) wrt movie_name for the last 5 records of dataframe.

import matplotlib.pyplot as plt

pb=pb.tail(5)

x=pb.loc[:,'movie_name']

y=pb.loc[:,'movie_total']

y1=pb.loc[:,'movie_total_worldwide']

plt.plot(x,y)

plt.plot(x,y1)

plt.grid(True)

plt.xlabel("Movie Names---->")

plt.ylabel("Total Earning----->")

plt.title("Movie Earnings")

plt.show()

18
BOLLYWOOD BOX OFFICE


# (Q17) WAP to plat a line graph for the following columns wrt movie_name with xticks
and rotation factor from the dataframe.

import matplotlib.pyplot as plt

pb=pb.head(10)

x=pb.loc[:,'movie_name']

y=pb.loc[:,'movie_opening']

pb.plot(kind='line', color=['gold','magenta'],

marker="*",markersize=10,linewidth=3,linestyle="--")

plt.title('Openings')

plt.xlabel('Movie Name-->')

plt.ylabel('Earnings-->')

ticks = pb.index.tolist()

plt.xticks(ticks,pb.movie_name,rotation=90)

plt.show()

19
BOLLYWOOD BOX OFFICE


# (Q18) WAP to creat a bar chart for the following data.

import matplotlib.pyplot as plt

Names=['Angrezi Medium','Simran','Haseena Parkar','Shubh Mangal Zyada Saavdhan']

Earnings_in_Cr=[4,11,6,20]

plt.bar(Names,Earnings_in_Cr)

plt.show()

20
BOLLYWOOD BOX OFFICE


# (Q19) WAP to create a bar chart on the following data with distinct colours of the bars.

import matplotlib.pyplot as plt

Names=['Thappad','Lucknow Central','Bhoomi','Shubh Mangal Zyada Saavdhan','Baaghi 3']

Runtime=[121,144,123,111,160]

ab=['Red','Yellow','Green','Blue','Pink']

plt.bar(Names,Runtime,color=ab,width=0.4)

plt.show()

21
BOLLYWOOD BOX OFFICE


#(Q20) WAP to create a horizontal bar chart on the same data as in (Q19).

import matplotlib.pyplot as plt

Names=['Thappad','Lucknow Central','Bhoomi','Shubh Mangal Zyada Saavdhan','Baaghi 3']

Runtime=[121,144,123,111,1

ab=['Red','Yellow','Green','Blue','Pink']

plt.barh(Names,Runtime,color=ab)

plt.show()

22
BOLLYWOOD BOX OFFICE


# (Q21) WAP to create a bar plot of the following data. Use multiple values on the
same chart.

import matplotlib.pyplot as plt

import numpy as np

Movie_Total=[20,15,18,23]

Worldwide=[26,21,23,29]

x=np.arange(len(Movie_Total))

plt.bar(x,Movie_Total,width=0.25,label="Movie_Total",color="Cyan",hatch='xx')

plt.bar(x+0.25,Worldwide,width=0.25,label="Worldwide", color="Red",hatch='oo')

plt.legend()

plt.xticks(x,['M1','M2','M3','M4'])

plt.show()

23
BOLLYWOOD BOX OFFICE


BIBLIOGRAPHY
https://colab.google.com
https://www.kaggle.com
https://ncert.nic.in/textbook.php

24
BOLLYWOOD BOX OFFICE


25

You might also like