tidytext Basics
Learn about the basic structure of a tidytext program.
We'll cover the following...
Key concepts of tidytext
tidytext is designed to streamline specific text analysis tasks, making it a valuable tool for text mining and natural language processing. It is focused on a limited but important set of tasks, such as:
Tokenization:
tidytexthelps us break down text documents into individual words or tokens. Theunnest_tokens()function is commonly used for this purpose, allowing us to specify how we want to tokenize our text (such as by word or by sentence).Sentiment analysis:
tidytextincludes functions for performing sentiment analysis on text data. We can use prebuilt sentiment lexicons, such as the Bing or AFINN lexicons, or create custom lexicons. Theget_sentiments()function retrieves sentiment lexicons, and the ...