ropensci / tidync

NetCDF exploration and data extraction
https://docs.ropensci.org/tidync
90 stars 12 forks source link

Silence outputs from tidync #115

Closed markpayneatwork closed 2 years ago

markpayneatwork commented 2 years ago

tidync is a fantastistic package that has really changed the way that I work with NetCDF files - thanks for the great work. One critique I would have is that the tidync() command is quite "chatty" - it gives lots of messages, which is handy for debugging, but can be irriating when processing thousands of files. Is it possible to add a silent=TRUE argument please (or perhaps verbosity levels)?

mdsumner commented 2 years ago

yes, fair enough - I'll have a look🙏

mdsumner commented 2 years ago

I will get to this, haven't forgotten. I expect I'll have a 'silent' argument with FALSE as default - and an option to set to always be quiet.

I'm not au fait with best practice on silent-ness so if you have any details or examples of other packages and how you interact with this I'll incorporate them.

mdsumner commented 2 years ago

ok can now do

op <- options(tidync.silent = TRUE)

## ... do stuff

## restore original option
options(op)

fdc6d46ddd321bc1472f4cf3d1ab382c4d3febd5

HTH