Ignore:
Timestamp:
09/01/16 07:55:20 (5 years ago)
Author:
mjuckes
Message:

updates

File:
1 edited

Legend:

Unmodified
Added
Removed
  • CMIP6dreqbuild/trunk/src/framework/overviewTabs.py

    r533 r546  
    3535        x = sc.volByExpt( l1, m2, expFullEx=True ) 
    3636        self.cc[m].a[m2] += x[0] 
     37        self.cc[m].a['TOTAL'] += x[0] 
    3738        dd = collections.defaultdict( list ) 
    3839        lll = set() 
     
    4950    oo = open( 'tab01_%s_%s.texfrag' % (tiermax,pmax), 'w' ) 
    5051    mmh = [] 
    51     mhdr = [ '\\rot{80}{%s}' % m for m in mipsp] 
     52    mhdr = [ '\\rot{80}{%s}' % m for m in mipsp + ['TOTAL',]] 
    5253    mhdrh = [ '<th><div><span>%s</span></div></th>' % m for m in mipsp] 
    5354    oo.write( string.join(['',] + mhdr, ' & ' ) + '\\\\ \n\\hline\n' ) 
     
    5758      ll = [m,] 
    5859      llh = [m,] 
    59       for m2 in mipsp: 
     60      ttl = 0. 
     61      for m2 in mipsp + ['TOTAL',]: 
    6062       if m2 in self.cc[m].dd: 
    6163        oo1 = open( 'html/tt/rq-%s-expt-%s.html' % (m,m2), 'w' ) 
     
    8082         
    8183         
     84       if m2 in self.cc[m].dd or m2 == 'TOTAL': 
    8285        if self.cc[m].a[m2] == 0: 
    8386          ll.append( '' ) 
     
    9497            else: 
    9598              s = '{:,.2f}'.format( self.cc[m].a[m2]*1.e-9 )  
     99            if m2 == 'TOTAL': 
     100              s = '{\\bf %s}' % s 
    96101            ll.append( s ) 
    97102            fn = '%s-%s_%s_%s.xlsx' % (m,m2,tiermax, pmax) 
Note: See TracChangeset for help on using the changeset viewer.