parameters: (ax, data, vals=None, **kwargs)
return_statement: return ax, cbar
docstring: Plot ERT data as pseudosection matrix (position over separation).
  
      Parameters
      ----------
      data : DataContainerERT
          data container with sensorPositions and a/b/m/n fields
      vals : iterable of data.size() [data('rhoa')]
          vector containing the vals to show
      ax : mpl.axis
          axis to plot, if not given a new figure is created
      cMin/cMax : float
          minimum/maximum color vals
      logScale : bool
          logarithmic colour scale [min(A)>0]
      label : string
          colorbar label
  
      **kwargs:
          * dx : float
              x-width of individual rectangles
          * ind : integer iterable or IVector
              indices to limit display
          * circular : bool
              Plot in polar coordinates when plotting via patchValMap
      Returns
      -------
      ax:
          The used Axes
      cbar:
          The used Colorbar or None
docstring_summary: Plot ERT data as pseudosection matrix (position over separation).
docstring_tokens: Plot ERT data as pseudosection matrix ( position over separation ) .
function: def drawERTData(ax, data, vals=None, **kwargs):
      """Plot ERT data as pseudosection matrix (position over separation).
  
      Parameters
      ----------
      data : DataContainerERT
          data container with sensorPositions and a/b/m/n fields
      vals : iterable of data.size() [data('rhoa')]
          vector containing the vals to show
      ax : mpl.axis
          axis to plot, if not given a new figure is created
      cMin/cMax : float
          minimum/maximum color vals
      logScale : bool
          logarithmic colour scale [min(A)>0]
      label : string
          colorbar label
  
      **kwargs:
          * dx : float
              x-width of individual rectangles
          * ind : integer iterable or IVector
              indices to limit display
          * circular : bool
              Plot in polar coordinates when plotting via patchValMap
      Returns
      -------
      ax:
          The used Axes
      cbar:
          The used Colorbar or None
      """
      if vals is None:
          vals = data('rhoa')
  
      valid = data.get("valid").array().astype("bool")
      vals = ma.array(vals, mask=~valid)
  
      ind = kwargs.pop('ind', None)
  
      if ind is not None:
          vals = vals[ind]
          mid, sep = midconfERT(data, ind)
      else:
          mid, sep = midconfERT(data, circular=kwargs.get('circular', False))
  
      # var = kwargs.pop('var', 0)  # not used anymore
      cbar = None
  
      dx = kwargs.pop('dx', np.median(np.diff(np.unique(mid))))*2
      ax, cbar, ymap = showValMapPatches(vals, xVec=mid, yVec=sep,
                                         dx=dx, ax=ax, **kwargs)
  
      if kwargs.get('circular', False):
          sM = np.mean(data.sensors(), axis=0)
          a = np.array([np.arctan2(s[1]-sM[1], s[0]-sM[0])
                        for s in data.sensors()])
          p = list(range(len(a)))
          # p.append(0)
          ax.plot(np.cos(a)[p], np.sin(a)[p], 'o', color='black')
  
          for i in range(len(a)):
              ax.text(1.15 * np.cos(a[i]),
                      1.15 * np.sin(a[i]), str(i+1),
                      horizontalalignment='center',
                      verticalalignment='center')
          ax.set_axis_off()
          ax.set_aspect(1)
  
      else:
          ytl = generateConfStr(np.sort([int(k) for k in ymap]))
          if 'DD1' in ytl and 'WB2' in ytl and 'DD2'not in ytl:
              ytl[ytl.index('DD1')] = 'WB1'
          if 'WA1' in ytl and 'SL2' in ytl and 'WA2'not in ytl:
              ytl[ytl.index('WA1')] = 'SL1'
  
          yt = ax.get_yticks()
          yt = np.unique(yt.clip(0, len(ytl)-1))
  #        if yt[0] == yt[1]:
  #            yt = yt[1:]
          dyt = np.diff(yt)
          if dyt[-1] < dyt[-2]:
              yt = yt[:-1]
          ax.set_yticks(yt)
          ax.set_yticklabels([ytl[int(yti)] for yti in yt])
      return ax, cbar
function_tokens: def drawERTData ( ax , data , vals = None , * * kwargs ) : if vals is None : vals = data ( 'rhoa' ) valid = data . get ( "valid" ) . array ( ) . astype ( "bool" ) vals = ma . array ( vals , mask = ~ valid ) ind = kwargs . pop ( 'ind' , None ) if ind is not None : vals = vals [ ind ] mid , sep = midconfERT ( data , ind ) else : mid , sep = midconfERT ( data , circular = kwargs . get ( 'circular' , False ) ) # var = kwargs.pop('var', 0)  # not used anymore cbar = None dx = kwargs . pop ( 'dx' , np . median ( np . diff ( np . unique ( mid ) ) ) ) * 2 ax , cbar , ymap = showValMapPatches ( vals , xVec = mid , yVec = sep , dx = dx , ax = ax , * * kwargs ) if kwargs . get ( 'circular' , False ) : sM = np . mean ( data . sensors ( ) , axis = 0 ) a = np . array ( [ np . arctan2 ( s [ 1 ] - sM [ 1 ] , s [ 0 ] - sM [ 0 ] ) for s in data . sensors ( ) ] ) p = list ( range ( len ( a ) ) ) # p.append(0) ax . plot ( np . cos ( a ) [ p ] , np . sin ( a ) [ p ] , 'o' , color = 'black' ) for i in range ( len ( a ) ) : ax . text ( 1.15 * np . cos ( a [ i ] ) , 1.15 * np . sin ( a [ i ] ) , str ( i + 1 ) , horizontalalignment = 'center' , verticalalignment = 'center' ) ax . set_axis_off ( ) ax . set_aspect ( 1 ) else : ytl = generateConfStr ( np . sort ( [ int ( k ) for k in ymap ] ) ) if 'DD1' in ytl and 'WB2' in ytl and 'DD2' not in ytl : ytl [ ytl . index ( 'DD1' ) ] = 'WB1' if 'WA1' in ytl and 'SL2' in ytl and 'WA2' not in ytl : ytl [ ytl . index ( 'WA1' ) ] = 'SL1' yt = ax . get_yticks ( ) yt = np . unique ( yt . clip ( 0 , len ( ytl ) - 1 ) ) #        if yt[0] == yt[1]: #            yt = yt[1:] dyt = np . diff ( yt ) if dyt [ - 1 ] < dyt [ - 2 ] : yt = yt [ : - 1 ] ax . set_yticks ( yt ) ax . set_yticklabels ( [ ytl [ int ( yti ) ] for yti in yt ] ) return ax , cbar