A data scientist must produce an initial exploratory analysis of customer comments using charts and a word cloud, and wants to apply feature engineering before building an NLP model. Which two feature-engineering techniques should be used to prepare text for visualization and modeling? (Choose two.)
Choose an answer
Tap an option to check your answer.
Correct answer: Stemming, Term frequency–inverse document frequency (TF‑IDF).
Why this is the answer
Stemming reduces words to their root form (e.g., "running," "ran," "runs" all become "run"), which is crucial for consolidating word counts for visualizations like word clouds and for reducing the dimensionality of text data for NLP models. TF-IDF assigns weights to words based on their frequency in a document relative to their frequency across all documents. This technique helps identify important words within a document while downplaying common words, making it excellent for feature engineering in NLP models and for highlighting significant terms in visualizations. Named entity recognition and sentiment analysis are NLP tasks themselves, not feature engineering techniques for preparing text. Coreference resolution identifies when different words refer to the same entity, which is a more advanced NLP task beyond basic feature engineering for initial analysis.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed