title: Histogram for data with periodic boundary conditions
body: <p>I'd like to make a histogram where the data live in periodic space but one bin intersects a boundary, that is, the leftmost and rightmost bins should be one and the same.</p>
  
  <p>For example, if I have angular data that ranges from <code>0</code> to <code>360</code>, and would like to make <code>N</code>, <code>S</code>, <code>E</code>, and <code>W</code> bins, the <code>N</code> bin should include data from <code>0</code> to <code>45</code> <em>and</em> from <code>315</code> to <code>360</code>.  I can't do something like <code>np.histogram(data, bins=[315,45,135,225,315])</code> because <code>bins must increase monotonically</code>.</p>
  
  <p>Of course, I could pretreat my data by 'rotating' it <code>data[data&gt;bins.max()] -= 360</code> but that seems like kind of a hack and was wondering if there is a cleaner way.</p>