title: Access the header/name of items in a pandas.core.series.Series serious
body: <p>I have the following code where I'm trying to pull dividends for a stock I own and access the corresponding ex date:</p>
  <pre><code>def get_all_dividends(ticker):
      yahoo_stock_obj = yf.Ticker(ticker.upper())
      dividends = yahoo_stock_obj.dividends
      names = numpy.unique(numpy.concatenate(dividends.apply(lambda x: [y['name'] for y in x])))
      import ipdb; ipdb.set_trace()
  
  
  get_all_dividends('psec')
  </code></pre>
  <p>I tried to use <a href="https://stackoverflow.com/questions/44159392/accessing-unique-items-from-a-pandas-core-series-series-dictionary">accessing unique items from a pandas.core.series.Series dictionary</a> but am getting a type error that the object being iterated over is a float not a string:</p>
  <pre><code>File &quot;C:\Users\Dave\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\pandas\core\apply.py&quot;, line 1143, in apply_standard
      mapped = lib.map_infer(
    File &quot;pandas\_libs\lib.pyx&quot;, line 2870, in pandas._libs.lib.map_infer
    File &quot;dividends.py&quot;, line 67, in &lt;lambda&gt;
      names = numpy.unique(numpy.concatenate(dividends.apply(lambda x: [y['name'] for y in x])))
  TypeError: 'float' object is not iterable
  </code></pre>
  <p>This is what I see when I look at dividends in ipython:</p>
  <p><a href="https://i.stack.imgur.com/kcl4M.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/kcl4M.png" alt="enter image description here" /></a></p>
  <p>I am doing something like <code>dividends[-1]</code> returns 0.12, the most recent special dividend. What I want is to be able to utilize a tuple like <code>('6-27-2022', 0.12)</code>.</p>