7.6.2.Final Exam - sj50179/IBM-Data-Science-Professional-Certificate GitHub Wiki

Final Exam

LATEST SUBMISSION GRADE 100%

Question 1

What does csvfile stand for?

  • car seller values
  • comma separated values

Correct

Question 2

Scikit-learn is used for?

  • Statistical modelling including regression and classification.
  • Fast array processing.

Correct

Question 3

What tells us the way the data is encoded?

  • Data path
  • File path
  • Encoding scheme

Correct

Question 4

What attribute or function returns the data types of each column?

  • head()
  • tail()
  • dtypes

Correct

Question 5

In a dataset what is the name of the columns?

  • Type
  • Row
  • Header

Correct

Question 6

The Matplotlib library is mostly used for what?

  • Data analysis
  • Machine learning
  • Data visualization

Correct

Question 7

What would the following code segment output from a dataframe df?

**df.head(5)**
  • It would return the first 5 rows of the dataframe
  • It would return the last 5 rows of the dataframe
  • It would return all of the rows of the dataframe

Correct

Question 8

What does the following code segment perform in a dataframe?

mean = df["normalized-losses"].mean()
df["normalized-losses"].replace(np.nan, mean)
  • It drops rows that contain missing values
  • It drops all of the rows in the column "normalized-losses"
  • It replaces the missing values in the column "normalized-losses" with the mean of that column

Correct

Question 9

How would you multiply each element in the column df["a"] by 2 and assign it back to the column df["a"]?

  • df["a"]=2*df["a"]
  • 2*df["a"]
  • df["a"]=df["a"]-1

Correct

Question 10

What function returns the maximum of the values requested for the requested column?

  • max()
  • min()
  • std()

Correct

Question 11

Since most statistical models cannot take objects or strings as inputs, what action needs to be performed?

  • Convert categorical variables into numerical values
  • Convert numerical values into categorical variables

Correct

Question 12

What function will change the name of a column in a dataframe?

  • rename()
  • exchange()
  • replace()

Correct