title: Python: Divide values in cell by max in each column
body: <p>Is this an efficient or correct way to divide every cell in each column by the maximum value in that column within a table? Is there a better implementation (if this is correct)?
  Note: All values >= 0</p>
  
  <pre><code>new_data = [];
  for row in np.transpose(data)[1::]: #from 1 till end
      for elements in row:
          if sum(elements) != 0:
              new_data.append(elements/max(row));
          else:
              new_data.append(0);
  new_data = np.transpose(new_data);
  </code></pre>
  
  <p>Now:</p>
  
  <pre><code>id col1 col2 col3 col4
  A   2    1    4    0
  B   3    8    2    0
  C   2    3    0    0
  D   5    5    3    0
  E   6    3    3    0
  </code></pre>
  
  <p>Required:</p>
  
  <pre><code>id col1 col2 col3 col4
  A  1/3  1/8  1     0  
  B  1/2  1    1/2   0
  C  1/3  3/8  0     0
  D  5/6  5/8  3/4   0
  E  1    3/8  3/4   0
  </code></pre>