Set max matplotlib version to 1.3.1.

Workaround to get our tests passing until #649 is fixed.
Merge pull request #650 from jairideout/mpl-131

Set max matplotlib version to 1.3.1