[ncl-talk] netcdf file compression
Douglas Lowe
Douglas.Lowe at manchester.ac.uk
Tue Sep 4 08:11:00 MDT 2018
Dear all,
I’m trying to use the file compression option listed on this manual page:
https://www.ncl.ucar.edu/Document/Functions/Built-in/setfileoption.shtml
This is my code:
file_chem = addfile(filename+”.nc", "w")
setfileoption(file_chem,"Format","NetCDF4")
setfileoption(file_chem,"CompressionLevel",4)
However, I am not finding that there’s any extra compression of the data compared to
using the default compression level - and if I compress the file myself using nccopy
I find I can greatly compress the file (5Mb down to 50kb).
Have I missed any extra code that I should be adding (my variable processing / writing
code is the same as I’d use for netcdf3 files) to make this compression work?
thanks,
Doug
More information about the ncl-talk
mailing list