title: The function to_excel of pandas generate an unexpected TypeError
body: <p>I created a dictionary of pandas dataframe:</p>
  
  <p><code>d[k] = pd.DataFrame(data=data[i])</code></p>
  
  <p>So I assume that <code>d[k]</code> is a correct pandas dataframe.</p>
  
  <p>Then</p>
  
  <pre><code>for k in d.keys():
    d[k].to_excel (file_name)
  </code></pre>
  
  <p>Then I have the error:</p>
  
  <p><code>TypeError: got invalid input value of type &lt;class 'xml.etree.ElementTree.Element'&gt;, expected string or Element</code></p>
  
  <p>I am using Python 3.7, pandas 0.25.3.</p>
  
  <p><strong>Update</strong>: if I replace <code>to_excel</code> by <code>to_csv</code>, the code runs perfectly.</p>