Challenge 2
Task
Swipe to start coding
So, now let's remember what we do with text data. You will be working with the 'reviews.csv'
dataset, and your task will be to encode text data using the bag of words method.
- Create a
CountVectorizer
object to tokenize text - Fit data to the tokenizer
- Print the vocabulary of the tokenizer
- Encode
'Text'
column - Print the results
Solution
Everything was clear?
Thanks for your feedback!
SectionΒ 6. ChapterΒ 2
single
Ask AI
Ask AI
Ask anything or try one of the suggested questions to begin our chat
Awesome!
Completion rate improved to 3.33
Challenge 2
Swipe to show menu
Task
Swipe to start coding
So, now let's remember what we do with text data. You will be working with the 'reviews.csv'
dataset, and your task will be to encode text data using the bag of words method.
- Create a
CountVectorizer
object to tokenize text - Fit data to the tokenizer
- Print the vocabulary of the tokenizer
- Encode
'Text'
column - Print the results
Solution
Everything was clear?
Thanks for your feedback!
Awesome!
Completion rate improved to 3.33SectionΒ 6. ChapterΒ 2
single