Error in gzfile(path.expand(tarfile), "rb") : cannot open the connection In addition: Warning message: In gzfile(path.expand(tarfile), "rb") : cannot open compressed file 'NA', probable reason 'Permission denied'


#1

I am trying to prepare Oli data using landsatlinkr, but I got this error first time. can you please tell me why?


#2

Hi chinthra, sorry about your recent troubles. Usually folks like to see as close to a reproducible example (reprex) as possible. In this case you might not be able to give us the file, but could you show the code snippet error as it appears in your console?

That being said,

  • the error message says "cannot open compressed file 'NA', probable reason 'Permission denied'", suggests your code is providing NA as a filepath. Does that ring true?
  • And the 'Permission denied' often appears when you don't have read permissions on that file.

#3

Thank you

Sorry I was unable to reply to you.
Actually, I am using landsatlinkr package available on Git Hub. I could manage to run until step 5 calibration. when I was running the last step of composite then I get memory problem. But I did this same process before without any problem. I am loading
library (landsatlinkr)
run_landsatlinkr

Then I follow the rest

I do not know whether this information work for you