From 1db7eab1db7c6e3bf76e77572aa6d4e56e7cf798 Mon Sep 17 00:00:00 2001 From: David C Danko Date: Tue, 28 Jan 2020 11:09:14 -0500 Subject: [PATCH] Add a dynamic import of timestamp from pandas Pandas seems to have moved the timestamp import over version, see this [issue](https://stackoverflow.com/questions/50591982/importerror-cannot-import-name-timestamp) --- ggplot/stats/smoothers.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ggplot/stats/smoothers.py b/ggplot/stats/smoothers.py index 5a8fbf37..dd72308f 100644 --- a/ggplot/stats/smoothers.py +++ b/ggplot/stats/smoothers.py @@ -1,7 +1,10 @@ from __future__ import (absolute_import, division, print_function, unicode_literals) import numpy as np -from pandas.lib import Timestamp +try: + from pandas.lib import Timestamp +except ImportError: + from pandas import Timestamp import pandas as pd import statsmodels.api as sm from statsmodels.nonparametric.smoothers_lowess import lowess as smlowess