nc = netCDF4.Dataset(filename, 'r') var = nc.variables['lon'] val = var[:] # 値 varname = var.long_name # 名前 unit = var.units # 単位 nc.close()