title: Pandas: Create DF with custom columns based on different DF
body: <p>I have two dataframes and need to either alter the second to fit the format of my first or I can create a new dataframe altogether. </p>
  
  <p>The first dataframe is simply...</p>
  
  <pre><code>stores_df = pd.DataFrame({'Stores': ['Kroger', 'United'], 'City':['Dallas','Austin']})
  
      Stores  City
  0   Kroger  Dallas
  1   United  Austin
  </code></pre>
  
  <p>The second is formatted like so (this is how it is given to me, I can't change it)...</p>
  
  <pre><code>apples_df = pd.DataFrame({'Color': ['Red', 'Green', 'Yellow','Red', 'Green', 'Yellow'], 'Store':['Kroger','Kroger','Kroger','United','United','United'], 'Ripe': ['20','17', '14', '23', '18', '0']})
  
      Color   Stores  Ripe
  0   Red     Kroger  20
  1   Green   Kroger  17
  2   Yellow  Kroger  14
  3   Red     United  23
  4   Green   United  18
  5   Yellow  United  0
  </code></pre>
  
  <p>My desired dataframe is the combination of both, except color value + column header 'Ripe' becomes the destination's column header and the count is added to each of the first dataframe's store row. Like so...</p>
  
  <pre><code>    Stores  City    Red Ripe    Green Ripe    Yellow Ripe
  0   Kroger  Dallas  20          17            14
  1   United  Austin  23          18            0
  </code></pre>
  
  <p>I'm somewhat familiar with merging/joining and messed around with pivot tables enough to realize I need some help. Thanks.</p>