- Timestamp:
- Jun 18, 2016, 4:38:48 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tools/nc_var_tools.py
r876 r877 8977 8977 Nvardims = len(vardims) 8978 8978 for ivd in range(Nvardims): 8979 if not objnewnc.variables.has_key(vardims[ivd]): 8980 objvdim = objnc.variables[vardims[ivd]] 8979 vdname = vardims[ivd] 8980 if not objnewnc.variables.has_key(vdname) and \ 8981 objnc.variables.has_key(vdname): 8982 objvdim = objnc.variables[vdname] 8981 8983 coinvardims = objvdim.dimensions 8982 8984 … … 8993 8995 # Introducing only that dimension variables with any dimension after the operation 8994 8996 if len(newdvards) > 0: 8995 newvar = objnewnc.createVariable(v ardims[ivd],\8996 vdimtype,tuple(newdvards))8997 newvar = objnewnc.createVariable(vdname, vdimtype, \ 8998 tuple(newdvards)) 8997 8999 newvar[:] = newdvarv 8998 9000 dimvattrs = objvdim.ncattrs()
Note: See TracChangeset
for help on using the changeset viewer.