title: Changing data types of elements in lists of lists
body: <p>I have an imported data file. </p>
  
  <p>It is a list made up of 51 lists. </p>
  
  <p>Each of the nested lists has 5 elements. </p>
  
  <p>I want to change 1 (The second element so location 1) of the 5 elements from string to integers.</p>
  
  <p>This is what I have:</p>
  
  <pre><code>for i in range(len(statesData)):
      statesData[i] = statesData[i].strip()
      statesData[i] = statesData[i].split(',')
      for d in statesData[i]:
          d[1] = int(d[1])
          d[2] = float(d[2])
  </code></pre>
  
  <p>Now I don't want element 1 (0) to be included since it is the heading of each category. </p>
  
  <p>I want to start with 2 (1). I was thinking a range function somewhere like: </p>
  
  <pre><code>statesData[i][1:]
  </code></pre>
  
  <p>But that doesn't seem to work. Any advice? I should be able to do this without too much trouble. Or having to create a function. </p>