title: segmented linear regression in python
body: <p>Is there a library in python to do <a href="http://en.wikipedia.org/wiki/Segmented_regression" rel="noreferrer">segmented linear regression</a>?
  I'd like to fit multiple lines to my data automatically to get something like this:
  <img src="https://i.stack.imgur.com/yFgSs.png" alt="segmented regression"></p>
  
  <p>Btw. I do know the number of segments.</p>