我试图从猎头公司获取统计数据。
library(RCurl)
library(jsonlite)
library(purrr)
library(stringr)
library(rvest)
library(dplyr)
library(jsonlite)
Sys.setlocale(locale = "Russian")
vacanciesdf <- data.frame(
Name = character(),
Currency = character(),
From = character(),
Area = character(),
Requerement = character(), stringsAsFactors = T,
Experience = character()
)
for (pageNum in 0:1) {
data <- jsonlite::fromJSON(paste0("https://api.hh.ru/vacancies?text=\"machine+learning\"&page=", pageNum))
vacanciesdf <- rbind(vacanciesdf, data.frame(
data$items$area$name,
data$items$salary$currency,
data$items$salary$from,
data$items$employer$name,
data$items$snippet$requirement,
data$items$experience$name
))
print(pageNum)
Sys.sleep(3)
}
行中出现错误:数据$ items $体验$ name,没有此行的代码有效。 完整错误文字:
Error in data.frame(data$items$area$name, data$items$salary$currency, :
arguments imply differing number of rows: 20, 0
答案 0 :(得分:0)
npm install @ionic/app-scripts@nightly --save-dev