2017-01-26 6 views
2

Export>Save as Web Page(RStudioで)を手動でクリックすることなく、wordcloud2パッケージによって生成された単語クラウドをhtmlとして自動的にエクスポートする方法はありますか? pdfをpdfで、画像をpngで保存するような何か?ここでwordcloud2をhtmlとして自動的にエクスポートしますか?

は、サンプルを生成するコードは、それが迅速に、より永久的な家にこのファイルを移動するのがベストでしょう

require(wordcloud2) 
df = head(demoFreq,50) 
wordcloud2(df) 

答えて

3
require(wordcloud2) 
df  <- head(demoFreq, 5) 
my_cloud <- wordcloud2(df) 
my_path <- htmltools::html_print(my_cloud) # saves html in temp directory 
print(my_path) # the location of the html file. 

をwordcloudています。

関連する問題