没有从开放数据中提取完整的JSON?

时间:2016-11-28 17:08:08

标签: json r opendata rjsonio

我想从开放数据中提取数据。

https://data.cityofnewyork.us/Transportation/For-Hire-Vehicles-FHV-Active-and-Inactive-Vehicles/8wbx-tsch

但我注意到,当我现在有更多时,我的代码只产生1000行数据。我在哪里错了?

#libraries
library(RJSONIO)

#pull data
a <- fromJSON("https://data.cityofnewyork.us/resource/k5sk-y8y9.json?$query= SELECT Base_number, Base_name, Base_type, Base_Address")

#loop to extract (I'm aware that sapply or 
#lapply may be better functions, how would I approach this issue with those?)
empty_a = NULL
for (i in a) {
  print(i)
  empty_a = rbind(empty_a, i)
}

empty_a = as.data.frame(empty_a)

0 个答案:

没有答案