How might I parse and process JSON that already lives inside a data frame?
Sample data:
df <- data.frame(
id = c("x1", "x2"),
y = c('[{"Property":"94","Value":"Error"},{"Property":"C1","Value":"Found Match"},{"Property":"C2","Value":"Address Mismatch"}]', '[{"Property":"81","Value":"XYZ"},{"Property":"D1","Value":"Blah Blah"},{"Property":"Z2","Value":"Email Mismatch"}]')
)
I want to extract, format and separate the raw JSON in column y
into orderly columns, ideally with library(jsonlite)
.
Thanks in advance!