Update plotting.py

Fix for Python2.7