The hardware and bandwidth for this mirror is donated by METANET, the Webhosting and Full Service-Cloud Provider.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]metanet.ch.

jsonNormalize

R-CMD-check

Normalize JSON strings.


library(jsonNormalize)

badJstring <- "
[
  { 01: false, 999: true, },
  {
    area: 30,
    thirty: '30',
    ind: [5, 4.1,   3.7 , 1e3,],
    'cluster'    : true  ,
    \"999\": false,
    city: 'London'
  },
  [ null, undefined,   NaN],
  {
    'null': null,
    'undefined': undefined,
    'NaN': NaN
  }
]"
goodJstring <- jsonNormalize(badJstring, prettify = TRUE)
cat(goodJstring)
[
  {
    "999": true,
    "01": false
  },
  {
    "999": false,
    "area": 30,
    "thirty": "30",
    "ind": [
      5,
      4.1,
      3.7,
      1000
    ],
    "cluster": true,
    "city": "London"
  },
  [
    null,
    "",
    ""
  ],
  {
    "null": null,
    "undefined": "",
    "NaN": ""
  }
]

These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.