docs: def view_elt(token, dstore):
      """
      Display the event loss table averaged by event
      """
      oq = dstore['oqparam']
      R = len(dstore['csm_info'].rlzs)
      dic = group_array(dstore['losses_by_event'].value, 'rlzi')
      header = oq.loss_dt().names
      tbl = []
      for rlzi in range(R):
          if rlzi in dic:
              tbl.append(dic[rlzi]['loss'].mean(axis=0))
          else:
              tbl.append([0.] * len(header))
      return rst_table(tbl, header)