From http://stackoverflow.com/questions/30416871/plots-getting-getting-chopped-off-in-python-notebook