parent
c03630a565
commit
12e1985b16
@ -0,0 +1,11 @@
|
||||
from wordcloud import WordCloud
|
||||
import matplotlib.pyplot as plt
|
||||
|
||||
|
||||
def make_wordcloud(count_dict):
|
||||
wc = WordCloud(background_color='white', width=800, height=600)
|
||||
text = " ".join([keyword + " " * count for keyword, count in count_dict.items()])
|
||||
wc.generate(text)
|
||||
plt.imshow(wc, interpolation='bilinear')
|
||||
plt.axis('off')
|
||||
plt.show()
|
Loading…
Reference in new issue