I have a JSON file. I would like to convert this JSON file into CSV. I have gone through several posts in the R Studio Community (here and here) and Stack Overflow. After reading them, I wrote a code.
My code is working only for the first row
. This means, I am getting only 1st row
from the JSON file. But, my JSON file containing 1024 rows. I check the file through the online website and received 1024 rows.
Compound <- fromJSON(file = "~/Compound.json")
df <- data.frame(t(sapply(Compound,c)))
Could you tell me, why I am getting only 1 row
or how can I solve these issues?