I have a large zip file with a bunch of geotiff files in it and a .vrt file with the needed info for each. Rather than unzip all the files, I'd like to work directly with the zip file.
This command, with the .vrt and some of the geotiff files works, in the sense that temp raster is created as a rasterLayer but since not all the geotiff files are unzipped, plot(rasterLayer) fails with a missing data error.
tempraster <- raster("data-raw/CoastalDEMv1.1/tiles.vrt")
This command fails, presumably because I has specified the path incorrectly
tempraster <- raster("data-raw/Global_90.zip/CoastalDEMv1.1/tiles.vrt")
The error message is
Error in .rasterObjectFromFile(x, band = band, objecttype = "RasterLayer",: Cannot create a RasterLayer object from this file. (file does not exist)
Presumably, this means raster thinks the zip part of the path is just another folder. I need it to look inside the zip.
I'm running on a Mac, OS is Catalina.