Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 13

Programs

1. Bar Graph
Source Code:
import pandas as pd
import matplotlib.pyplot as plt
data = open("macintosh/Users/harshshah/Downloads//Ip Dastaset.csv")
df = pd.read_csv(data)

plt.bar(df['Company'],df['Avg. sale per month'],color='blue')


plt.xlabel('Company')
plt.ylabel('No. Customer')

plt.xticks(('TATA','Jaguar','Audi','BMW','Maruti Suzuki','Mercedes',
'Hyundai','Honda','Volvo','Ford','Isuzu','Toyota','Jeep',
'Volkswagen'), rotation = 'vertical')

plt.show()

Output:

Description
A bar chart or bar graph is a chart that presents categorical data with
rectangular bars with heights or lengths proportional to the values that
they represent. bar() is used to plot vertical bar graphs.

The following graph compares the No. of customers ,15500 being the
highest number of customers and 6700 being the lowest number of
customers.
2.Line Graph
Source Code:
import pandas as pd
import matplotlib.pyplot as plt
data = open("macintosh/Users/harshshah/Downloads//Ip Dastaset.csv”)
df = pd.read_csv(data)

plt.plot(df['Cars'],df['Ratings'],color='gold', marker = '.', markeredgecolor = 'black')


plt.xlabel('CARS')
plt.ylabel('RATINGS')

plt.xticks(('Nano','Kwid','Alto k10','Santro','Tiago','Celerio X','Ignis',


'Etios','Bolt','Xcent','Polo','Freestyle','Jazz',
'Compass','Mu-X','A3','Xc40','B-class','Xf','X5'),rotation = 'vertical')
plt.show()

Output:

Description:
A line chart or line graph is a type of chart that displays information
as a series of data points called ‘markers’ connected by straight line
segments. plot()is used to plot a line graph.
The following graph helps us to analyze the ratings given by the
customers who bought the particular car model, hence gathering
the data in the same place.
3.Histogram

Source Code:
import pandas as pd
import matplotlib.pyplot as plt
data = open("macintosh/Users/harshshah/Downloads//Ip Dastaset.csv")
df=pd.read_csv(data)
plt.hist(df['Ratings'],bins=None,color='orange’')

plt.xlabel('Ratings')
plt.xticks([1,2,3,4,5,6,7,8,9,10])

plt.show

Output:

Description:
A histogram provides a visual interpretation of numerical data by
indicating the number of data points that lie within a range of values.
hist() is used to plot a histogram.
The following graph represents the ratings of the car model per
customer.
4.Horizontal Bar Graph
Source Code:
import pandas as pd
import matplotlib.pyplot as plt
data = open("macintosh/Users/harshshah/Downloads//Ip Dastaset.csv")
df=pd.read_csv(data)
plt.barh(df['Price'],df['Ratings'],color='violet')

plt.xlabel('Avg. sale per month')


plt.ylabel('Ratings')

plt.show()

Output:

Description
barh() is used to plot horizontal bar graphs.
The following graph displays the ratings given to a specific car
having its specific price.
5. Double Bar Graph

Input:
import pandas as pd
import matplotlib.pyplot as plt
import numpy as np

data = open("macintosh/Users/harshshah/Downloads//Ip Dastaset.csv")


df = pd.read_csv(data)
X = np.arange(20)
plt.bar(X+0.00, df['Ratings'], width = 0.40, color = 'orange',label = 'Ratings' )
plt.bar(X+0.40, df['Ownership'], width = 0.40, color = 'violet', label = 'Ownership')

plt.legend(loc = 'upper right')


plt.show()

Output:

Description:
Multiple bar graphs are used to plot multiple data ranges on the same bar
chart creating multiple bars. PyPlot does not provide a specific function for
this, but it can be created by exploiting the ‘width’ and ‘color’ arguments of
bar().
The following graph compares the ratings given to the car with the ownership
of that specific car. Here, the orange bar represents the ratings and the violet
bar represents the ownership of the car.

Dataset of average sales of


different cars per month at Cars24

Avg. sale per


C_ID Company Cars Price Ratings Ownership
month
1001 TATA Nano Rs.2,96,000 12154 1 1
1002 Renault Kwid Rs.4,63,000 11540 4 2
1003 Maruti Suzuki Alto k10 Rs.4,07,000 15500 9 1
1004 BMW X5 Rs.82,90,000 8850 9 1
1005 Hyundai Santro Rs.5,68,000 9232 7 3
1006 TATA Tiago Rs.5,90,000 8494 2 1
1007 Maruti Suzuki Celerio X Rs.4,89,000 14450 4 2
1008 Maruti Suzuki Ignis Rs.5,83,000 6679 6 2
1009 Toyota Etios Rs,6,02,000 8969 7 1
1010 Jaguar Xf Rs.55,67,000 6789 10 1
1011 TATA Bolt Rs.6,45,000 6700 9 2
1012 Hyundai Xcent Rs.5,56,000 11251 8.5 3
1013 Volkswagen Polo Rs.7,34,000 14999 10 2
1014 Ford Freestyle Rs.6,81,000 5737 3 1
1015 Honda Jazz Rs.8,03,000 9085 6 2
1016 Jeep Compass Rs.26,12,000 7520 8 1
1017 Isuzu Mu-X Rs.29,34,000 6836 7 1
1018 Audi A3 Rs.31,11,000 10898 9 2
1019 Volvo Xc40 Rs.43,55,000 13576 9 2
1020 Mercedes B-class Rs.30,12,000 12380 5 2

We have collected the dataset of Cars24 which provides car retail services.
For this project we have only focused on the used cars retail services.
The above data set includes the list of the car models offered by Cars24 with the
prices and ratings mentioned. It shows the average sales of cars per month who
have bought a particular car from the list and also the price.
PREFACE
In this project we will simplify and analyze the data collected
from different car companies. The following simplification of the
data set into visual forms of graphs will help the future car
customers to scan the data at a simple glance, hence making
the whole process time effective.

OBJECTIVE
The automobile industry today is the most profitable industry. Due
to increase in the income in both rural and urban sectors and
availability of easy finance are the main drivers of high volume car
segments. The objective of this project is to visualize and provide
various insights from the considered Indian automobile dataset by
performing data analysis. The considered dataset is of Indian cars,
that consists of various features such as company name , model,
average sales per month, ratings given to the car, cost of the car.
The insights that could be estimated from this dataset would be
features such as price of a specific car model that could be
estimated using the other attributes of that particular car .

It will also give us the information about the total number of


customers preferring a certain car model offered by the car retailer
and also their respective ratings through our proposed system,
which will help not only the car retailer to maintain accurate data of
their customers but also the Car companies to understand their
market and retail of a cars and improve their models in terms of
feedbacks from the customers. They can increase the
manufacturing of their most preferred car model sensing the
demand and also work towards the less preferred car models by
changing and rebuilding it according to the presented needs of
their consumers. Hence, it will help them to increase sales of the
retailer and work towards improving lacking models that aren’t in
demand as of now, resulting in overall profit of the car company.
Conclusion
By the completion of the project, we conclude that this
project can be useful for simplified analysis of the data
of any Car retail services taking into consideration that
the right data is stored accordingly.
This project also helps us to get to know the brief idea of
the trends of the Automobile industry and helps us in
analyzing and also helps the Customers and Employees
to evaluate the sales of the cars. It will also help the
company to take effective steps to improve the sales of
cars.

References

The Data is Collected from


https://www.cars24.com
https://www.v3cars.com
SINHGAD PUBLIC SCHOOL,
LONAVALA

Informatics Practices Project

Name: Harsh Shah | Arya Ghangale

Examination Seat no.: |

AISSCE (2022-23)
Certificate

It gives me immense pleasure to forward this project of


Informatics Practices titled ‘data management and analysis
of car retail consumer preference.’ for AISSCE-2022-23
practical examination.
The student has performed the project in a satisfactory manner.
I certify that Harsh Shah has completed the project under my
guidance. The data mentioned in the project is based on his
original findings.

(Mrs. Rima Salve) (Mrs. Nilam Patil) (Mr. NK Mishra)


(PGT-IP) (PGT-CS) (PRINCIPAL)

SCHOOL STAMP EXTERNAL EXAMINER


ACKNOWLEDGEMENT

We would like to thank our Informatics Practices teacher


Mrs. Rima Salve ma’am and Mrs. Nilam Patil ma’am as
well as our respected Principal Mr. N K Mishra sir, for
giving us the opportunity to work on this project and
providing valuable guidance to complete the same. We are
very grateful to them. This project helped us enhance our
thinking abilities and work out of our comfort zone, hence
helping us learn new things and concepts in a very
interesting manner. We would also like to express special
gratitude to our parents for their useful feedback and
encouragement. Their support throughout the project helps
us to do better.

Name: Harsh Shah


Class XII
2022-23

INDEX

Sr. No. Content

1 Preface

2 Objective

3 Dataset

4 Programs

5 Conclusion

6 References

You might also like