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

Informatics Practical File (Upl Fil)

Uploaded by

janakihari07
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 views27 pages

Informatics Practical File (Upl Fil)

Uploaded by

janakihari07
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/ 27

INDEX

SL NO. TOPIC PG NO.


1. Top 3 Largest and Smallest areas in a DataFrame
6
2. Data Series and Indexing
7
3. Series Sorting
8
4. Square of Series Values Greater than 15
9
5. Temperature Data Series
10
6. DataFrame Column selection
11
7. Handling Missing Data
12
8. Append Data to DataFrame
13-14
9. Calculating Weighted Marks
15
10. Creating Series Objects from Rows of a DataFrame
16
11. Creating a DataFrame from a List of Dictionaries
17
12. Plotting Variations using a Line Chart
18-19
13. Plotting Monthly Orders on a Horizontal Bar Graph
20
14. Creating Histograms
21-23
15. Plotting Multiple Datasets on the same Histogram
24-25
16. Creating a Bar Graph for Favourite Ice Cream Flavours
26
17. Creating a Bar Graph
27
18. DataBase Mangement System
28-30

1|Pa g e
1. Top 3 Largest and Smallest Areas in a Data Series

AIM:
To find out biggest and smallest values from given series

PROGRAM:
Given a Series that stores the areas of some states in km^2. Write a code to find out
the biggest and smallest three areas from the given Series.
LIBRARY USED:
 Pandas

SOURCE CODE:

OUTPUT:

2|Pa g e
2. Data Series and Indexing
AIM: Write a program to create a data series and then change the
indexes of the series object in random order.
LIBRARY USED: Pandas

SOURCE CODE:

OUTPUT:

3|Pa g e
3.Series Sorting
AIM:
Write a program to sort the values of a series object s1 in descending
order of its indexes and store it into series object s3.

LIBRARY USED:
Pandas

SOURCE CODE:

OUTPUT:

4|Pa g e
4.Square of Series Values Greater than 15
AIM:
Given a series object s5, store the squares of series values in s6 and
display values > 15.
LIBRARY USED:
Pandas

SOURCE CODE:

OUTPUT:

5|Pa g e
5. Temperature Data Series
AIM:
Create a Series object Temp1 to store temperatures of seven random
days.

SOURCE CODE:

OUTPUT:

6|Pa g e
6. DataFrame Column Selection
AIM: Write a Pandas program to select the 'name' and 'score' columns
from a DataFrame.
SOURCE CODE:

OUTPUT:

7|Pa g e
7. Handling Missing Data
AIM: Select rows where the score is missing (NaN) in the DataFrame.

SOURCE CODE:

OUTPUT:

8|Pa g e
8. Append Data to DataFrame
AIM: Append a dictionary to the existing DataFrame.
LIBRARY USED: Pandas
SOURCE CODE:

9|Pa g e
OUTPUT:

10 | P a g e
9. Calculating Weighted Marks
AIM: Calculate final marks from three term Series using weighted
formula.
SOURCE CODE:

OUTPUT:

11 | P a g e
10. Creating Series Objects from Rows
of a DataFrame
AIM: Write a program to create three different Series objects from the
three rows of a DataFrame df.
SOURCE CODE:

OUTPUT:

12 | P a g e
11. Creating a DataFrame from a List
of Dictionaries
AIM: A list stores three dictionaries, each storing details of old
price, new price, and change. Write a program to create a
DataFrame from this list.

SOURCE CODE:

OUTPUT

13 | P a g e
DATA VISUALIZATION

12. Plotting Stock Price Variations


Over 3 Months Using Line Chart
AIM: Write a program to display stock price variations for 3 months
using 3 lines on the same line chart. Add legends, labels, and a grid.

SOURCE CODE:

14 | P a g e
OUTPUT:

15 | P a g e
13. Plotting Monthly Orders on a
Horizontal Bar Chart
AIM: Navya has an online business. Write a program to plot the number
of orders in the last 6 months on a horizontal bar chart.
SOURCE CODE:

OUTPUT:

16 | P a g e
14. CREATING HISTOGRAMS
AIM: Given weight measurements (in grams) for 16 small orders of
French-fries, create different types of histograms:

 (a) Simple histogram


 (b) Horizontal histogram
 (c) Step-type histogram
 (d) Cumulative histogram

SOURCE CODE:
a) Himple histogram

b) Horizontal histogram

c) Step-type histogram

d) Cumulative histogram

17 | P a g e
OUTPUT:
a)

b)

18 | P a g e
c)

d)

19 | P a g e
15. Plotting Multiple Datasets on the
Same Histogram
AIM: Create an ndarray with 16 values and plot this array along with the
previous weight dataset on the same histogram:
o (a) Normal histogram
o (b) Cumulative histogram
o (c) Horizontal histogram

SOURCE CODE:

a) Normal Histogram

b) Cumulative Histogram

c) Horizontal Histogram

20 | P a g e
OUTPUT:
a)

b)

c)

21 | P a g e
16.Creating a Bar Graph for Favorite
Ice Cream Flavors
AIM: Write a program to create a bar graph showing the favorite ice
cream flavors among students.
SOURCE CODE:

OUTPUT:

22 | P a g e
17. CREATING A BAR GRAPH

AIM: Write a program to create a grouped bar graph showing the amounts of
different vegetables sold at Frank's Farm Stand over three days.

SOURCE CODE:

OUTPUT:

23 | P a g e
18. DataBase Management System

24 | P a g e
25 | P a g e
AIM: Find the total number of customers from each country in the table (customer
ID, customer Name, country) using group by.
SOURCE CODE:

OUTPUT:

AIM: Write a SQL query to order the (student ID, marks) table in descending
order of the marks.
SOURCE CODE:

OUTPUT:

26 | P a g e
27 | P a g e

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy