wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Pandas, NumPy and Matplotlib

Total questions: 10

Worksheet time: 50secs

Name
Class
Date
1.

NumPy is mainly used for:

a)

Creating websites

b)

Fast numerical operations with arrays

c)

Drawing cartoons

d)

Writing novels

2.

Which of these is faster for numerical tasks in Python?

a)

Python lists

b)

NumPy arrays

c)

Excel sheets

d)

Text files

3.

Which function creates an array of evenly spaced numbers between two values?

a)

linspace()

b)

zeros()

c)

describe()

d)

groupby()

4.

In NumPy, which function returns an array filled with all zeros?

a)

np.ones()

b)

np.zeros()

c)

np.arange()

d)

np.empty()

5.

Pandas stores tabular data using which structure?

a)

List

b)

DataFrame

c)

Array

d)

Dictionary

6.

Which Pandas method quickly gives count, mean, min, max, and quartiles?

a)

.aggregate()

b)

.describe()

c)

.summarize()

d)

.compute()

7.

In Pandas, to group data by a column and get averages, you use:

a)

.mean() directly

b)

.groupby()

c)

.sort_values()

d)

.loc[]

8.

Which Python library is used to create visualizations like line plots, bar charts, and scatter plots?

a)

NumPy

b)

Pandas

c)

Matplotlib

d)

TensorFlow

9.

Which Matplotlib function creates a simple line graph?

b)

plt.scatter()

c)

plt.plot()

d)

plt.pie()

10.

To draw a histogram of ages in Matplotlib, you would use:

b)

plt.age()

c)

plt.line()

d)

plt.hist()