title: create a pandas data frame from several lists
body: <p>My function outputs a list, for instance when I type:</p>
  
  <pre><code>My_function('TV', 'TV_Screen')
  </code></pre>
  
  <p>it outputs the following:</p>
  
  <pre><code>['TV', 1, 'TV_Screen', 0.04, 'True']
  </code></pre>
  
  <p>Now, my TV is made of several parts, such as speaker, transformer, etc., I can keep running my function for each part, and for instance change 'TV_Screen' for 'TV_Speaker', or 'TV_transformer', etc.</p>
  
  <p>The alternative is to create a list with all the part, such as:</p>
  
  <pre><code>TV_parts = ['TV_Screen', 'TV_Speaker', 'TV_transformer']
  </code></pre>
  
  <p>What I am trying to get is a pandas data frame with 5 columns (because my function outputs 5 variables, see above the section "it outputs the following:") and in this case 3 rows (one of each for 'TV_Screen', 'TV_Speaker', and 'TV_transformer'). Basically, I want the following to be in a data frame: </p>
  
  <pre><code>['TV', 1, 'TV_Screen', 0.04, 'True']
  ['TV', 9, 'TV_Speaker', 0.56, 'True']
  ['TV', 3, 'TV_transformer', 0.80, 'False']
  </code></pre>
  
  <p>I know I need a for loop somewhere, but I am not sure how to create this data frame. Could you please help? (I can change the output of my function to be a pd.Series or something else that would work better).</p>
  
  <p>Thanks!</p>