title: 'TypeError: can't multiply sequence by non-int of type 'float'' finding the max. in Python
body: <p>Here, from a large data file split into different rows with the same 4th column. The third column represents mass, but it isn't always the largest value in the row. I'm trying to plot a line, with only the highest 10% of masses:</p>
  
  <p>My code is as follows:</p>
  
  <pre><code>M1 = max(str(int(row1[i][2]))) #maximum value from row1, 3rd column
  M2 = max(str(int(row2[j][2])))
  
  if row1[i][2] &gt;= M1*(0.1):
     plt.plot....
  </code></pre>
  
  <p>this gives me the error:</p>
  
  <pre><code>if row1[i][2] &gt;= M1*float(0.1):
  TypeError: can't multiply sequence by non-int of type 'float'
  </code></pre>
  
  <p>My rows look like this (each row on separate line):</p>
  
  <pre><code>[[1, -1, 10, 0]]
  [[2, 1, 2, 19]]
  [[3, 2, 15, 20], [4, 2, 50, 20], [5, 2, 90, 20]]
  [[6, 3, 15, 21]]
  [[7, 4, 50, 40]]
  [[8, 5, 90, 50]]
  [[9, 6, 13, 60]]
  [[10, 7, 50, 65]]
  [[11, 8, 70, 74], [12, 8, 95, 74], [13, 8, 75, 74]].....
  </code></pre>
  
  <p>Any help would be greatly appreciated!! Thanks in advance</p>