How to convert categorical variables into numerical variables in Python?

preview_player
Показать описание
Sometimes datasets contain categorical variables in the string format, and since the model cannot understand the string format, we need to convert them into numeric form. Pandas provide an inbuilt function named get_dummies for this purpose. It is used when the categorical variables do not have preferences or weights attached to them. This video teaches you to use Pandas get_dummies function to convert categorical variables into numerical variables in Python.
Why ProjectPro? With ProjectPro, you get access to 100,000+ lines of verified, downloadable code and 50,000+ minutes of videos and practical hands-on experience from real industry projects as well as Tech support and 1-1 sessions.
So, check out ProjectPro - the only solution for solved industrial-grade projects.
Subscribe to our channel to get the video updates.
Рекомендации по теме
Комментарии
Автор

Thanks for watching. I would love to learn about what projects you are working on. Please leave a comment below.

ProjectProDataScienceProjects