R jsonlite: Read JSON Snippets

options(width = 150)
options(max.print = 30)

I have some json files exported from a mongodb database. Now, I am going to read and process them using R jsonlite library.

result = jsonlite::fromJSON("data/plan_jobs.json")
result
##                          $oid     depot max_drops max_vol_tol shortStatus             status          submitDate   $numberLong trailer_eff_volM3
## 1    59259c9b4eb11bdcb734897d     ADANA         4          10           G         TAMAMLANDI 2017-05-24 17:45:47 1495637147081                73
## 2    5926703e4eb11bdcb73489e4     CORLU         4          10           G         TAMAMLANDI 2017-05-25 08:48:45 1495691325885                55
##      truck_eff_volM3           user lg_truck_eff_volM3
## 1                 33          admin                 NA
## 2                 33     plan_corlu                 NA
##  [ reached getOption("max.print") -- omitted 1296 rows ]

 Tech    3 Feb, 2018

Any work (images, writings, presentations, ideas or whatever) which I own is always provided under
Creative Commons License Creative Commons Attribution-Share Alike 3.0 License

Mert Nuhoglu is a Trabzon-born programmer and data scientist.

You may also like...