How to fix the error in R of “no lines available in input”?

前端 未结 2 1625
失恋的感觉
失恋的感觉 2021-01-11 09:42

What I need to do is to read data from hundreds of links, and among them some of the links contains no data, therefore, as the codes here:

urls <-paste0(\         


        
2条回答
  •  旧时难觅i
    2021-01-11 10:32

    Does this help?

      dims <- sapply(myData, dim)[2,]
      bad_Ones <- myData[dims==1]
      good_Ones <- myData[dims>1]
    

    If myData still grabs something off the station page, the above code should separate the myData list into two separate groups. good_Ones would be the list you would want to work with. (assuming the above is accurate, of course)

提交回复
热议问题