help for gzipuse                             (Nikos Askitas)

Use and save compressed dta files. Compress .dta files.

gzipuse filename[.dgz] [,clear] will use a gzipped dta file. gzipsave filename[.dgz] [,replace remove verbose] will save data in mem > ory to filename.dgz.

Description These three modules are disk space saving utilities. Stata .dta files are known to compress well (sizes go down by factors of up to about 20). If you are deali > ng in volumes of these things it can get expensive... The penalty you pay is a small delay when you gzipuse or gzipsave.

gzipuse: uses gzipped files ending in .dgz. You may or may not specify the suffix. You may or may not specify the clear option. The bahavior is the one you know from stata's use.

gzipsave: saves data in memory in compressed form with a .dgz suffix in addition to the .dta. If you specify the replace option it will overwrite existing .dta .dgz files with the same name. The remove optio > n removes the .dta file. The verbose option will return the disk saving in percentage if you kept the .dgz file only.

Technical note

gzipuse and gzipsave were written and tested on a Unix system. If it does not work directly on windows a small amount of tweaking will get it going there as well.

You can convert existing files into .dgz files by either useing them and then gzipsaveing them or by doing ! gzip -c filename.dta | filename.dgz. If you have a filename.dgz and you need to restore it into a .dta version just do ! gzcat -S.dgz filename.dgz > filename.dta.

You may need to edit the files and set the paths to your rm, gzip, gzcat comman > ds correctly. We suggest installing ashell (i.e. ssc install ashell) since in its presence the user path will be queried about the paths to the commands. Author

Dr Nikos Askitas, IZA, Bonn, Germany. Email: nikos@@iza.org