How to solve "bad restore file magic number" when trying to load data?

Viewed 1295

I tried to load data to my R working directory and receive this error:

Error: bad restore file magic number (file may be corrupted) -- no data loaded
In addition: Warning message:
file ‘classize.RData’ has magic number 'RDX3'
  Use of save versions prior to 2 is deprecated

I googled it and tried many options, unsuccessfully.

  1. My Rstudio version is: 1.2.5033 (The error was happening before updating as well)
  2. I create a new project, in the new directory, I put the data file
  3. The data file is "classize.RData"
  4. I have another alternative which is "classize.RDS" with the sugesstion to use readRDS(file = "classize.RDS"). When using this command, I receive that error:
  cannot read workspace version 3 written by R 3.6.1; need R 3.5.0 or newer

This is in the context of a statistical course at university and my teacher assistant is unable to help me out, and whitout resolving this issue, I cannot move forward in the resolution of the needed exrecices. So please, couly you help me resolve that problem.

ps: all the students have access to the same data, It's just for me that it's not working, therefore the file should not be corrupted.

0 Answers
Related