code: def length(self, chain=-1):
          
          if chain is not None:
              return len(self._vlarrays[chain])
          else:
              return sum(map(len, self._vlarrays))
docs: Return the length of the trace.
  
          :Parameters:
          chain : int or None
            The chain index. If None, returns the combined length of all chains.