[问题类型]:
程式咨询(我想用R 做某件事情,但是我不知道要怎么用R 写出来)
[软件熟悉度]:
入门(写过其他程式,只是对语法不熟悉)
[问题叙述]:
我想抓气象局表格资料(逐三小时预报,想知道温度/降雨机率),如下网址
https://www.cwb.gov.tw/V7/forecast/town368/towns/6300200.htm?layer=0&type=Weather&time=7Day
[程式范例]:
library(rvest)
a<-read_html("https://www.cwb.gov.tw/V7/forecast/town368/towns/6300200.htm?layer=0&type=Weather&time=7Day")
b<-html_nodes(a,"table")
c<-html_table(b)
出来的结果
Error in utils::type.convert(out[, i], as.is = TRUE, dec = dec) : invalid multibyte string at '<e6><97><85>?<8a>'
想请教正确的方法,十分感谢!!!!
[关键字]:
网络爬虫
环境叙述:
R version 3.4.3 (2017-11-30)
Platform: x86_64-w64-mingw32/x64 (64-bit)
win10 专业版