Made pandas import safe in plotting