Page 235 - Touhpad Ai
P. 235
3. Select the function that allows you to replace missing values with a specified value in Pandas.
a. replace() b. fillna()
c. drop() d. sort_values()
4. Spot the function used to remove leading and trailing spaces from a string.
a. df['column_name'].str.strip() b. df['column_name'].str.lower()
c. df['column_name'].str.replace() d. df['column_name'].str.split()
5. Mark the correct meaning of "validating the data".
a. Re-checking the cleaned data b. Making a graph
c. Downloading a dataset d. Printing the column names
6. Identify the first step to take after downloading a CSV file from Kaggle.
a. Email it to a friend b. Load it into a DataFrame
c. Open it in Paint d. Post it on social media
7. Which of these is an example of data transformation?
a. Removing duplicates b. Changing “Yes” to 1 and “No” to 0
c. Filling missing values d. Checking column names
8. Choose the reason why standardisation is important before analysis.
a. To increase dataset size b. To combine and compare data easily
c. To print the values d. To remove charts
9. Select the task that is part of data transformation.
a. Downloading the data b. Installing Pandas
c. Writing column names d. Converting units
10. Why should we clean data before using it in an AI model?
a. To save time b. To get accurate and reliable results
c. To make it look nice d. To reduce file size
11. How does data standardisation help when combining datasets from two different schools?
a. By making graphs automatically
b. By changing students' names
c. By ensuring formats (like date and marks) are the same
d. By removing all rows
12. Identify the best action when missing values are very few and not important.
a. Fill with average b. Ignore them
c. Drop those rows d. Set to 0
B. Fill in the blanks.
1. Pandas provides two primary data structures and .
2. is another Python library for numerical computing.
3. attribute returns the number of rows and columns in the DataFrame.
4. is an online platform for data science, machine learning, and AI enthusiasts.
5. The function is used to convert text to lowercase in Pandas.
Theoretical and Practical Aspects of Data Processing 233

