title: time series decomposition error in python
body: <p>I have the following dataframe</p>
  
  <pre><code>data = pd.DataFrame({
  'date': [1988, 1988, 2000, 2005],
  'value': [11558522, 12323552, 13770958, 18412280]
  }) 
  </code></pre>
  
  <p>i then make the date column into a datetime dtype</p>
  
  <pre><code>data['date'] = pd.to_datetime(data['date'],format = '%Y')
  </code></pre>
  
  <p>when i print the dtypes i get</p>
  
  <pre><code>print(data.dtypes)
  
  &gt;&gt;&gt; Register No.
  &gt;&gt;&gt; date    datetime64[ns]
  &gt;&gt;&gt; Sum              int64
  &gt;&gt;&gt; dtype: object
  </code></pre>
  
  <p>I then use the following code to make a time series decomposition</p>
  
  <pre><code>from pylab import rcParams
  from statsmodels.tsa.seasonal import seasonal_decompose 
  rcParams ['figure.figsize'] = 18,8
  decomposition = seasonal_decompose(data, model='additive', freq=30)
  fig = decomposition.plot()
  </code></pre>
  
  <p>But i get the following error</p>
  
  <pre><code>---------------------------------------------------------------------------
  TypeError                                 Traceback (most recent call last)
  &lt;ipython-input-54-e3a60d7302da&gt; in &lt;module&gt;
        3 
        4 rcParams ['figure.figsize'] = 18,8
  ----&gt; 5 decomposition = seasonal_decompose(data, model='additive', freq=30)
        6 
        7 fig = decomposition.plot()
  
  ~/opt/anaconda3/lib/python3.7/site-packages/statsmodels/tsa/seasonal.py in seasonal_decompose(x, model, filt, freq, two_sided, extrapolate_trend)
      113     nobs = len(x)
      114 
  --&gt; 115     if not np.all(np.isfinite(x)):
      116         raise ValueError("This function does not handle missing values")
      117     if model.startswith('m'):
  
  TypeError: ufunc 'isfinite' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ''safe''
  </code></pre>
  
  <p>i do not have any missing values in my dataframe and im not sure why am getting this error</p>