From the course: Deep Learning with Python and Keras: Build a Model for Sentiment Analysis

Unlock this course with a free trial

Join today to access over 24,900 courses taught by industry experts.

Visualizing text using word clouds

Visualizing text using word clouds

- [Instructor] Let's visualize the sentences we have in the different sentiment categories using a word cloud. A word cloud is a visual representation of text data where words from the text are displayed in different sizes with the size of each word proportional to its frequency of occurrence. Now, I don't know about you, but I find that writing code for visualizations to display charts, graphs, et cetera, in exactly the right format, is rather harder than it should be. And this is where I really like to use white coding. And here is my very high level prompt. Can you display a word cloud visualization for only the positive sentences in the financial data data frame? And it gives me great fully fleshed out code. Now I'm going to make a few changes, especially to the dimensions of the word cloud representation. So I just accept and I make those changes manually. On the first line, we access all of the sentences with…

Contents