microsoft / python-in-excel

Python in Microsoft Excel
MIT License
490 stars 31 forks source link

The preview should show the Python version of the data, not the Excel version #47

Open fzumstein opened 7 months ago

fzumstein commented 7 months ago

When you click on the card icon to see the preview, I can see a preview of the data the way it will be returned to Excel. This doesn't give me much, as I can simply toggle to Value mode and get the same. However, what I can't see is how the data/DataFrame looks in Python. E.g., will an empty cell be None or NaN or does this integer arrive as int or float? In essence, I think the preview that Jupyter notebook shows would be of much more value. You could even think of adding df.info() to the preview, as this turns up far away in the Diagnostics pane and can be buried by other messages that have popped up in the meantime.

keyur32 commented 7 months ago

Thanks. THis is a known bug with our card views. We currently show #NUM! in cases, when you have a Python object, instead of the None or NaN. Will let you know when updated.

fzumstein commented 7 months ago

Cool, it's not just about NA values, though. The index should also be shown, no matter whether it's the default index or not.

keyur32 commented 4 months ago

Missed your last comment here. Thanks for that feedback. We'll discuss offline on if we can or want to show that.