How to create tag clouds

[ ]


The most simple way is to use a Python package wordcloud. Then you can generate a word cloud with the following code:

from wordcloud import WordCloud
import matplotlib.pyplot as plt
wc = WordCloud()
text = open(r"222.txt",encoding='utf-8').read()

This is the example:

Django service

There is a free service in 词云助手 let you generate a tag cloud and you can even specify the image for the cloud. For example, with this as background:

We can get

Written on September 20, 2017