code: def _add_metadata_as_attrs_da(data, units, description, dtype_out_vert):
      
      if dtype_out_vert == 'vert_int':
          if units != '':
              units = '(vertical integral of {0}): {0} kg m^-2)'.format(units)
          else:
              units = '(vertical integral of quantity with unspecified units)'
      data.attrs['units'] = units
      data.attrs['description'] = description
      return data
docs: Add metadata attributes to DataArray