JSON File from Twitter shifting columns


I have downloaded some Tweets from Twitter for analysis in a JSON file. This loads into R fine, but when I turn it into a data frame to do my analysis it seems some of the columns are not in the correct order. For example, for the most part in the ID column, this is filled with the Tweet ID, but in some places the columns have shifter and the Tweet text or date is seen in this column.

I can see this is the case in file before I even load it into R - When I open this file in notebook I can see that the order of the column headings are not always the same.

Any idea how I can fix this?



Welcome to the RStudio community!

In order for us to help you with your question, please provide us a minimal reproducible example where you provide a minimal (dummy) dataset and code that can recreate the issue. Once we have that, we can go from there. For help on creating a Reprex, see this guide:

Good luck!

Looks like this was a bug in the Twitter API which seems to be fixed now.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.