title: Pandas inner product of rows
body: <p>I have</p>
  
  <pre><code>df={'x1':[1,2,3,4],
      'x2':[5,6,7,8],
      'y1':[1,2,1,1],
      'y2':[1,1,1,1],
      }
  df=pd.DataFrame(df)
  </code></pre>
  
  <p>it looks like</p>
  
  <pre><code>  x1 x2 y1 y2
     1  5  1  1
     2  6  2  1
     3  7  1  1
     4  8  1  1
  </code></pre>
  
  <p>how do I get a new column in df x1*y1+x2*y2 as "inner product" ?
  first attempt is</p>
  
  <pre><code>df['inner']=(df[['x1','x2']*df[['y1','y2']]).sum(axis=1)
  </code></pre>
  
  <p>but failed</p>
  
  <p>should be easy but somehow cannot find any easy answer</p>