title: Python: TypeError: unsupported operand type(s) for /: 'float' and 'list'
body: <p>I'm trying to do a trapz integration, with a function using 2 lists and 1 <code>numpy.ndarray</code>. It won't work, and I can't work out whether I need to convert my lists to some other data type. I'm happy that the actual function is correct, but I'm not sure how to proceed?</p>
  
  <p>The function is:</p>
  
  <pre><code>BB_flux = trapz((1./lamz)*flux*T,x=lamz)/trapz((1./lamz)*T,x=lamz)
  </code></pre>
  
  <p>where <code>T</code> and <code>lamz</code> are lists and <code>flux</code> is a ndarray that I have made by interpolation.</p>
  
  <p>Both <code>T</code> and <code>lamz</code> are made by reading from a csv file and then appending the values to <code>T</code> and <code>lamz</code> as floats.</p>