w.generate(txt) 向WordCloud对象中加载文本txt
w = wordcloud.WorldCloud()
w.generate("Python and wordcloud")
w.to_file(filename) 将词云输出为图像文件,.png格式或.jpg格式
w = wordcloud.WorldCloud()
w.to_file("outfile.png")
wordcloud库常规方法
阅读 109
2022-03-10
w.generate(txt) 向WordCloud对象中加载文本txt
w = wordcloud.WorldCloud()
w.generate("Python and wordcloud")
w.to_file(filename) 将词云输出为图像文件,.png格式或.jpg格式
w = wordcloud.WorldCloud()
w.to_file("outfile.png")
相关推荐
精彩评论(0)