aboutsummaryrefslogtreecommitdiff
path: root/py/table.py
blob: 8b6b38a8f05f18f4b4ccec173aa82d246be83fb7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
from data import trials

for trial in trials:
  print('\\multirow{' + str(len(trial.pits)) + '}{' +
  '$\\times$'.join([str(el) for el in trial.size]) + '}')
  nei = trial.nearest_neighbor()
  pitcnt = len(trial.pits)
  for pitind in range(pitcnt):
    pit = trial.pits[pitind]
    print('& %.1f& %.1f& %.2f\\cr' % (pit.depth, pit.diam, nei[pitind]))
    if pitind+1 == pitcnt:
      break
    print('\\cline');
  print('\\multispan{4}\\leaders\\hrule\\hfil\\cr')