特定の都道府県の賃貸物件の着工数をえる。
国交省の【住宅】利用関係別 構造別 建て方別 都道府県別 戸数 (Excel ファイル 3,225KB)
をダウンロード
http://www.mlit.go.jp/sogoseisaku/jouhouka/sosei_jouhouka_tk4_000002.html
readxlパッケージの利用
http://anpontan382.hatenablog.com/entry/2017/06/22/070514
install.packages("readxl") library(readxl) tyakou_y<-NULL tyakou_x<-NULL for(i in 1:30){ xls <- read_excel("../001218891.xls",sheet=i,range="C161:C161",col_names = FALSE,col_types = "text") xls2 <- read_excel("../001218891.xls",sheet=i,range="A3:A3",col_names = FALSE,col_types = "text") tyakou_y[i]<-as.vector(xls[[1]]) tyakou_x[i]<-as.vector(xls2[[1]]) cat(i,"\n") }