ensuring valid variable names for NetCDF4