Deedle icon indicating copy to clipboard operation
Deedle copied to clipboard

Import from xlsx

Open alexpantyukhin opened this issue 6 years ago • 4 comments

The Pandas has read_excel for dataframe. I think that it would be good to have it in the Deedle.

alexpantyukhin avatar Aug 20 '18 09:08 alexpantyukhin

Reading excel is a great productivity feature. I think we need to have more discussion about how to move forward on this issue.

pandas has optional dependency on xlrd to read excel files. I used to use OpenXml to read excel files. It is already on netstandard. But I'm not sure whether Deedle itself should have dependency on it or not.

Deedle.Excel currently depends on NetOffice and uses COM to interop with Excel. It's quite cool to have Excel open and Deedle frame directly shows up on the sheet. But COM interop will not work cross platform.

zyzhu avatar Aug 20 '18 13:08 zyzhu

I believe that having a separated dependency which provides import (and export in future) into Excel would be good. If consumer of the Deedle would like to work with Excel, there would be ability install it separately and use.

Actually I didn't look on the Deedle.Excel before (didn't know it exists :) ). I couldn't find sources of it.

alexpantyukhin avatar Aug 20 '18 13:08 alexpantyukhin

@alexpantyukhin It's a very old pull #399. I just quickly merged it with new fsproj format. I've never used it before either. But I tried the sample script and it's quite cool to use. https://github.com/fslaborg/Deedle/blob/master/src/Deedle.Excel/Deedle.Excel.Sample.fsx

zyzhu avatar Aug 20 '18 13:08 zyzhu

Deedle.Excel currently depends on NetOffice and uses COM to interop with Exce.lIt's quite cool to have Excel open and Deedle frame directly shows up on the sheet. But COM interop will not work cross platform.

Probably this can be resolved using ExcelDataReader or EPPlus: both are cross platform solutions, but the former one can only read excel xls + xlsx files, while the latter one can read excel xls + xlsx files and write xlsx files (and there's an upcoming license change for next EPPlus version). Both libraries are simpler but powerful when used to simply read(and write) data.

DGuidi avatar Feb 05 '20 14:02 DGuidi