フリー問題

SnowPro Advanced: Data Scientist のフリー問題 6 / 20 問目

問題文

A categorical column holds the payment method with four possible values that have no natural order. The model is a linear model. Which encoding is appropriate, and what would go wrong with the alternative?

選択肢

  1. One-hot encoding, because assigning integers to unordered categories lets the model read an order and a distance that do not exist.
  2. Either encoding, used for the payment method column in this model, because with only four categories the difference between them is too small to affect the fitted coefficients.
  3. Label encoding, because it keeps the number of columns small for the payment method and a linear model is not sensitive to the particular integers that were assigned to the categories.
  4. Leave the column as text, with the four payment method values in place, because the model can read the category names directly and will learn a coefficient for each name.

解答・解説を確認するには

正解と解説の確認、回答の記録には無料登録が必要です。登録すると演習モードでフリー問題に回答し、正誤と解説をその場で確認できます。