polaris.tasks.ocean.analysis.sim_files.year_range_key

polaris.tasks.ocean.analysis.sim_files.year_range_key(start_year, end_year)[source]

Get the key for a range of years, used both for step subdirectories and for the names of published files

The zero-padded convention matches the one ncclimo already uses in its output file names.

Parameters:
  • start_year (int) – The first year of the range, inclusive

  • end_year (int) – The last year of the range, inclusive

Returns:

key (str) – The range key, e.g. '0021-0040'