# Formats

## CAMS RA format

nes.nes_formats.cams_ra_format.create_dimension_variables(self, netcdf)

  Create the ‘time’, ‘time_bnds’, ‘lev’, ‘lat’, ‘lat_bnds’, ‘lon’ and ‘lon_bnds’ variables.

  ### Parameters

  selfnes.Nes

    Source projection Nes Object.

  netcdfDataset

    netcdf4-python open dataset.

nes.nes_formats.cams_ra_format.create_dimensions(self, netcdf)

  Create ‘time’, ‘time_bnds’, ‘lev’, ‘lon’ and ‘lat’ dimensions.

  ### Parameters

  selfnes.Nes

    Source projection Nes Object.

  netcdfDataset

    netcdf4-python open dataset.

nes.nes_formats.cams_ra_format.create_variables(self, netcdf, i_lev)

  Create the netCDF file variables.

  ### Parameters

  selfnes.Nes

    Source projection Nes Object.

  netcdfDataset

    netcdf4-python open dataset.

nes.nes_formats.cams_ra_format.date2num(time_array, time_units=None, time_calendar=None)

nes.nes_formats.cams_ra_format.to_netcdf_cams_ra(self, path)

  Horizontal methods from one grid to another one.

  ### Parameters

  selfnes.Nes

    Source projection Nes Object.

  pathstr

    Path to the output netCDF file.

## CMAQ format

nes.nes_formats.cmaq_format.change_variable_attributes(self)

  Modify the emission list to be consistent to use the output as input for CMAQ model.

  ### Parameters

  selfnes.Nes

    Nes Object.

nes.nes_formats.cmaq_format.create_dimension_variables(self, netcdf)

  Create the ‘y’ and ‘x’ variables.

  ### Parameters

  selfnes.Nes

    Nes Object.

  netcdfDataset

    NetCDF object.

nes.nes_formats.cmaq_format.create_dimensions(self, netcdf)

  Create ‘time’, ‘time_bnds’, ‘lev’, ‘lon’ and ‘lat’ dimensions.

  ### Parameters

  selfnes.Nes

    Nes Object.

  netcdfDataset

    netcdf4-python open dataset.

nes.nes_formats.cmaq_format.create_tflag(self)

  Create the content of the CMAQ variable TFLAG.

  ### Parameters

  selfnes.Nes

    Nes Object.

  ### Returns

  numpy.ndarray

    Array with the content of TFLAG.

nes.nes_formats.cmaq_format.create_variables(self, netcdf)

  Create the netCDF file variables.

  ### Parameters

  selfnes.Nes

    Nes Object.

  netcdfDataset

    netcdf4-python open dataset.

nes.nes_formats.cmaq_format.set_global_attributes(self)

  Set the NetCDF global attributes.

  ### Parameters

  selfnes.Nes

    Nes Object.

nes.nes_formats.cmaq_format.str_var_list(self)

  Transform the list of variable names to a string with the elements with 16 white spaces.

  ### Parameters

  selfnes.Nes

    Nes Object.

  ### Returns

  str

    List of variable names transformed on string.

nes.nes_formats.cmaq_format.to_cmaq_units(self)

  Change the data values according to the CMAQ conventions

  ### Parameters

  selfnes.Nes

    Nes Object.

  ### Returns

  dict

    Variable in the MONARCH units.

nes.nes_formats.cmaq_format.to_netcdf_cmaq(self, path, chunking=False, keep_open=False)

  Create the NetCDF using netcdf4-python methods.

  ### Parameters

  selfnes.Nes

    Source projection Nes Object.

  pathstr

    Path to the output netCDF file.

  chunking: bool

    Indicates if you want to chunk the output netCDF.

  keep_openbool

    Indicates if you want to keep open the NetCDH to fill the data by time-step.

## MONARCH format

nes.nes_formats.monarch_format.to_monarch_units(self)

  Change the data values according to the MONARCH conventions.

  ### Parameters

  selfnes.Nes

    Nes Object.

  ### Returns

  dict

    Variable in the MONARCH units.

nes.nes_formats.monarch_format.to_netcdf_monarch(self, path, chunking=False, keep_open=False)

  Create the NetCDF using netcdf4-python methods.

  ### Parameters

  selfnes.Nes

    Source projection Nes Object.

  pathstr

    Path to the output netCDF file.

  chunking: bool

    Indicates if you want to chunk the output netCDF.

  keep_openbool

    Indicates if you want to keep open the NetCDH to fill the data by time-step.

## WRF CHEM format

nes.nes_formats.wrf_chem_format.change_variable_attributes(self)

  Modify the emission list to be consistent to use the output as input for WRF-CHEM model.

  ### Parameters

  selfnes.Nes

    Nes Object.

nes.nes_formats.wrf_chem_format.create_dimension_variables(self, netcdf)

  Create the ‘y’ and ‘x’ variables.

  ### Parameters

  selfnes.Nes

    Nes Object.

  netcdfDataset

    NetCDF object.

nes.nes_formats.wrf_chem_format.create_dimensions(self, netcdf)

  Create ‘time’, ‘time_bnds’, ‘lev’, ‘lon’ and ‘lat’ dimensions.

  ### Parameters

  selfnes.Nes

    Nes Object.

  netcdfDataset

    netcdf4-python open dataset.

nes.nes_formats.wrf_chem_format.create_times_var(self)

  Create the content of the WRF-CHEM variable times.

  ### Parameters

  selfnes.Nes

    Nes Object.

  ### Returns

  numpy.ndarray

    Array with the content of TFLAG.

nes.nes_formats.wrf_chem_format.create_variables(self, netcdf)

  Create the netCDF file variables.

  ### Parameters

  selfnes.Nes

    Nes Object.

  netcdfDataset

    netcdf4-python open dataset.

nes.nes_formats.wrf_chem_format.set_global_attributes(self)

  Set the NetCDF global attributes

  ### Parameters

  selfnes.Nes

    Nes Object.

nes.nes_formats.wrf_chem_format.to_netcdf_wrf_chem(self, path, chunking=False, keep_open=False)

  Create the NetCDF using netcdf4-python methods.

  ### Parameters

  selfnes.Nes

    Source projection Nes Object.

  pathstr

    Path to the output netCDF file.

  chunking: bool

    Indicates if you want to chunk the output netCDF.

  keep_openbool

    Indicates if you want to keep open the NetCDH to fill the data by time-step.

nes.nes_formats.wrf_chem_format.to_wrf_chem_units(self)

  Change the data values according to the WRF-CHEM conventions.

  ### Parameters

  selfnes.Nes

    Nes Object.

  ### Returns

  dict

    Variable in the MONARCH units.