nctoolkit.create_ensemble

nctoolkit.create_ensemble(path='', recursive=True)

Generate an ensemble

Parameters
  • path (str) – The directory to search for netCDF files

  • recursive (boolean) – True/False depending on whether you want to search the path recursively. Defaults to True.

Returns

A list of files

Return type

list

Examples

If you wanted to recursively find all netCDF files available in a directory “data”, you would do this:

>>> import nctoolkit as nc
>>> nc.create_ensemble("data")

If you wanted to find the files in that directory and ignore subdirectories, you would instead do this:

>>> nc.create_ensemble("data", recursive = False)