title: Understanding NumPy's Convolve
body: <p>When calculating a simple moving average, <code>numpy.convolve</code> appears to do the job.</p>
  
  <p><strong>Question:</strong> How is the calculation done when you use <code>np.convolve(values, weights, 'valid')</code>? </p>
  
  <p>When the docs mentioned <code>convolution product is only given for points where the signals overlap completely</code>, what are the 2 signals referring to?</p>
  
  <p>If any explanations can include examples and illustrations, it will be extremely useful.</p>
  
  <pre><code>window = 10
  weights = np.repeat(1.0, window)/window
  smas = np.convolve(values, weights, 'valid')
  </code></pre>