Archive
Draw a word cloud with a R Shiny app

Draw a word cloud with a R Shiny app

2024-11-25 UPDATE: Due to the limitation in terms of maximum number of Shiny apps that can be published on the free shinyapps.io plan, the Shiny app presented be

Draw a word cloud with a R Shiny app

UPDATE: Due to the limitation in terms of maximum number of Shiny apps that can be published on the free shinyapps.io plan, the Shiny app presented below has been unpublished. However, the code can be found on GitHub.

Below a Shiny app to help you draw a word cloud:

Word clouds are particularly useful as part of text mining analyses. Moreover, it is also useful to analyze string and character variables for any datasets (see the different data types in R).

How to use this app ?

  • In Word source you can see two examples of word clouds with preloaded texts. If you want to use your own file, choose the option “Upload a file”
  • When uploading a file, make sure to upload a .csv or .txt file
  • If it is a .csv file , there should be only one column contain all word or sentence ( see example file : example.csv and example.txt )
  • Choose the language of the text. Stop words in the chosen language will be automatically removed
  • number and punctuation will be automatically remove as well , regardless of the language
  • You can remove specific words by specifying them after having clicked on “Remove specific words?”. Indicate one word per line
  • change the default option in Maximum number of word and background color if need
  • If you need to display this word cloud in your analyses, you can simply take a screenshot and include it in your document

code

Here is the entire code (or see the last version on GitHub) in case you would like to enhance it. See an example on how to use this app after the embedded code.

Note that the link may not work if the app has hit the monthly usage limit. Try again later if that is the case.

conclusion

Thanks for reading.

I is hope hope you will find this app useful to draw word cloud of your text .

As always, if you have a question or a suggestion related to the topic covered in this article, please add it as a comment so other readers can benefit from the discussion.