Changeset 472 in lmdz_wrf for trunk/tools


Ignore:
Timestamp:
Jun 10, 2015, 12:06:48 PM (9 years ago)
Author:
lfita
Message:

Adding multiple vardims and fixing legend position in 'draw_lines'

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/drawing.py

    r471 r472  
    15471547    vartit = values.split(':')[4]
    15481548    title = values.split(':')[5].replace('|',' ')
    1549     graphk = values.split(':')[6]
     1549    locleg = values.split(':')[6]
     1550    graphk = values.split(':')[7]
    15501551
    15511552    Nfiles = len(ncfiles)
     
    15851586            print errormsg
    15861587            print '  ' + fname + ": netCDF file '" + filen +                         \
    1587               "' does not have variables '" + dimvname + "' !!"
     1588              "' does not have variables '" + dimvnames + "' !!"
    15881589            quit(-1)
    15891590
     
    16031604        for dimvn in dimvname:
    16041605            if drw.searchInlist(objfile.variables, dimvn):
    1605                 vdobj = objfile.variables[dimvname]
     1606                vdobj = objfile.variables[dimvn]
    16061607                if len(vdobj.shape) != 1:
    16071608                    print errormsg
     
    16211622        ifn = ifn + 1
    16221623
    1623 
    16241624    drw.plot_lines(dimvalues, varvalues, valuesaxis, dimtit, leglabels.split(','),   \
    1625       vartit, varunits, title, graphk)
     1625      vartit, varunits, title, locleg, graphk)
    16261626
    16271627    return
Note: See TracChangeset for help on using the changeset viewer.