Is there a way to remove elements from a JSON using R?
Here's an example of a file I'm working with:
[
{
"var1_id": 1,
"var2_id": 2,
"var3_id": 3
},
{
"var1_id": 4,
"var2_id": 5,
"var3_id": 6
},
{
"var1_id": 7,
"var2_id": 8,
"var3_id": 9
}
]
I want to use R to remove the line for var2_id in each list, while keeping var1_id and var3_id. How could I do that?