Created
July 27, 2013 05:33
-
-
Save tattyamm/6093872 to your computer and use it in GitHub Desktop.
ニコニコ動画コメント等データから、動画コメントを取り出す例
http://www.nii.ac.jp/cscenter/idr/nico/nico-apply.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 動画コメントを取り出す例 | |
#install.packages("rjson") | |
library("rjson") | |
json_file <- "/ファイルの場所/sm57.dat" | |
thread<-file(json_file,"r") | |
for(i in 1:10000000){ | |
line <- readLines(con=thread,1) | |
json_data <- fromJSON(line) | |
print(json_data$comment) | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment