+1 vote
in Machine Learning by

Why do we need to convert categorical variables into factor? Which functions are used to perform the conversion?

1 Answer

0 votes
by

Most Machine learning algorithms require number as input. That is why we convert categorical values into factors to get numerical values. We also don't have to deal with dummy variables.

The functions factor() and as.factor() are used to convert variables into factors.

Related questions

0 votes
asked Nov 16, 2021 in Azure by Robin
0 votes
asked Aug 11, 2022 in GoLang by SakshiSharma
...