ODF spreadsheets

classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

ODF spreadsheets

Mats Hedlund
Is there any work being done for import/export to ODF spreadsheets?

_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

Jordi Gutiérrez Hermoso
On 17/01/2008, Mats Hedlund <[hidden email]> wrote:
> Is there any work being done for import/export to ODF spreadsheets?

Not that am I aware of, but do you really need it? Can't you use CSV
format instead?

Spreadsheets havea  lot of extra data that isn't easily representable
in Octave anyways (formulae, formatting, cells that are more than one
column or row wide....). If you just want the numbers, you should be
able to use CSV to both import and export.

Or if you *really* want Octave to read ODF spreadsheets, well, it
wouldn't be difficult except that we might have to add gzip to
Octave's build dependencies.

- Jordi G. H.
_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

kensmith
On Thursday 17 January 2008 12:39, Jordi Gutiérrez Hermoso wrote:

> On 17/01/2008, Mats Hedlund <[hidden email]> wrote:
> > Is there any work being done for import/export to ODF spreadsheets?
>
> Not that am I aware of, but do you really need it? Can't you use CSV
> format instead?
>
> Spreadsheets havea  lot of extra data that isn't easily representable
> in Octave anyways (formulae, formatting, cells that are more than one
> column or row wide....). If you just want the numbers, you should be
> able to use CSV to both import and export.

The formatting seems to me to be the one reason to do it.  Octave could
write spreadsheets that have the formatting set based on some logic
within the Octave program.

Being into electronics, I have a few times had to manually adjust
columns and change the units based on the data I ended up with.  A
classic example would be deciding to use K ohms or not based on the
highest resistance in the column.
 
>
> Or if you *really* want Octave to read ODF spreadsheets, well, it
> wouldn't be difficult except that we might have to add gzip to
> Octave's build dependencies.

Or maybe not.  The ODF outputter could take the address of the zip
program as a parameter and check at run time that it is there.

>
> - Jordi G. H.
> _______________________________________________
> Help-octave mailing list
> [hidden email]
> https://www.cae.wisc.edu/mailman/listinfo/help-octave

--
[hidden email]

_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

Muthiah Annamalai-3
kensmith wrote:

> On Thursday 17 January 2008 12:39, Jordi Gutiérrez Hermoso wrote:
>  
>> On 17/01/2008, Mats Hedlund <[hidden email]> wrote:
>>    
>>> Is there any work being done for import/export to ODF spreadsheets?
>>>      
>> Not that am I aware of, but do you really need it? Can't you use CSV
>> format instead?
>>
>> Spreadsheets havea  lot of extra data that isn't easily representable
>> in Octave anyways (formulae, formatting, cells that are more than one
>> column or row wide....). If you just want the numbers, you should be
>> able to use CSV to both import and export.
>>    
>
> The formatting seems to me to be the one reason to do it.  Octave could
> write spreadsheets that have the formatting set based on some logic
> within the Octave program.
>
> Being into electronics, I have a few times had to manually adjust
> columns and change the units based on the data I ended up with.  A
> classic example would be deciding to use K ohms or not based on the
> highest resistance in the column.
>  
>  
>> Or if you *really* want Octave to read ODF spreadsheets, well, it
>> wouldn't be difficult except that we might have to add gzip to
>> Octave's build dependencies.
>>    
>
> Or maybe not.  The ODF outputter could take the address of the zip
> program as a parameter and check at run time that it is there.
>
>
>  
For anyone interested in doing this work, a good starting point would be
look at
Gnumeric / Gnome-spreadsheet's OO.o export facilities, and rewrite the
same into
an OCT file. This will also be license compatible.
-Muthu


_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

Nicolas Pettiaux-3
2008/1/23, Muthiah Annamalai <[hidden email]>:
> kensmith wrote:
> > On Thursday 17 January 2008 12:39, Jordi Gutiérrez Hermoso wrote:
> >
> >> On 17/01/2008, Mats Hedlund <[hidden email]> wrote:
> >>
> >>> Is there any work being done for import/export to ODF spreadsheets?
> >>>
> >> Not that am I aware of, but do you really need it? Can't you use CSV
> >> format instead?

this is a way to go but

> For anyone interested in doing this work, a good starting point would be
> look at
> Gnumeric / Gnome-spreadsheet's OO.o export facilities, and rewrite the
> same into
> an OCT file. This will also be license compatible.

any direct link (aka octave being able to read/write data directly in
a ods spreadsheet)
would help by putting octave nearly on par with matlab that can do
this with excel spreadsheet, a feature that is used by some and
advertised by mathworks. In Belgium (and many other countries) where
ODF become standards pushed forward at least in public
administrations, this could well help.

Thanks,

Nicolas

--
Nicolas Pettiaux - email: [hidden email]
Utiliser des formats ouverts et des logiciels libres -
http://www.passeralinux.org.
Pour la bureautique, les seuls formats ISO sont ceux de http://fr.openoffice.org

_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

Jordi Gutiérrez Hermoso
In reply to this post by Muthiah Annamalai-3
On 23/01/2008, Muthiah Annamalai <[hidden email]> wrote:
> kensmith wrote:
> > On Thursday 17 January 2008 12:39, Jordi Gutiérrez Hermoso wrote:
> >
> >> On 17/01/2008, Mats Hedlund <[hidden email]> wrote:
> >>
> >>> Is there any work being done for import/export to ODF spreadsheets?
[snip]
> For anyone interested in doing this work, a good starting point would be
> look at
> Gnumeric / Gnome-spreadsheet's OO.o export facilities, and rewrite the
> same into
> an OCT file.

So this would require Octave to recognise a new Spreadsheet data
type... cell arrays or numeric matrices don't seem like they would fit
spreadsheets in them.

On second thought, if you really want to represent all the data of a
spreadsheet in Octave, this seems like a nontrivial task.

- Jordi G. H.

_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

Muthiah Annamalai-3
In reply to this post by Nicolas Pettiaux-3
Nicolas Pettiaux wrote:

> 2008/1/23, Muthiah Annamalai <[hidden email]>:
>  
>> kensmith wrote:
>>    
>>> On Thursday 17 January 2008 12:39, Jordi Gutiérrez Hermoso wrote:
>>>
>>>      
>>>> On 17/01/2008, Mats Hedlund <[hidden email]> wrote:
>>>>
>>>>        
>>>>> Is there any work being done for import/export to ODF spreadsheets?
>>>>>
>>>>>          
>>>> Not that am I aware of, but do you really need it? Can't you use CSV
>>>> format instead?
>>>>        
>
> this is a way to go but
>
>  
>> For anyone interested in doing this work, a good starting point would be
>> look at
>> Gnumeric / Gnome-spreadsheet's OO.o export facilities, and rewrite the
>> same into
>> an OCT file. This will also be license compatible.
>>    
>
> any direct link (aka octave being able to read/write data directly in
> a ods spreadsheet)
> would help by putting octave nearly on par with matlab that can do
> this with excel spreadsheet, a feature that is used by some and
> advertised by mathworks. In Belgium (and many other countries) where
> ODF become standards pushed forward at least in public
> administrations, this could well help.
>
> Thanks,
>
> Nicolas
>
>  
Who will bell the cat? Its a question of developer time I believe.
-Muthu


_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

Muthiah Annamalai-3
In reply to this post by Jordi Gutiérrez Hermoso
Jordi Gutiérrez Hermoso wrote:

> On 23/01/2008, Muthiah Annamalai <[hidden email]> wrote:
>  
>> kensmith wrote:
>>    
>>> On Thursday 17 January 2008 12:39, Jordi Gutiérrez Hermoso wrote:
>>>
>>>      
>>>> On 17/01/2008, Mats Hedlund <[hidden email]> wrote:
>>>>
>>>>        
>>>>> Is there any work being done for import/export to ODF spreadsheets?
>>>>>          
> [snip]
>  
>> For anyone interested in doing this work, a good starting point would be
>> look at
>> Gnumeric / Gnome-spreadsheet's OO.o export facilities, and rewrite the
>> same into
>> an OCT file.
>>    
>
> So this would require Octave to recognise a new Spreadsheet data
> type... cell arrays or numeric matrices don't seem like they would fit
> spreadsheets in them.
>
> On second thought, if you really want to represent all the data of a
> spreadsheet in Octave, this seems like a nontrivial task.
>
> - Jordi G. H.
>
>  
There is a school of thought that says spreadsheets are functional
programming languages.
Well, we have Octave and can abstract this. But rudimentary data I/O
from Octave
to whatever spreadseet must be the first goal that most people care about.
Feature kill is not required, IMHO.
-Muthu


_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

Tribo Laboy
In reply to this post by Mats Hedlund
Hello.

Is this anywhere close to what you are looking for?

http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=18222&objectType=file

I confirmed it works under MATLAB, but under Octave on WinXP I Have
some problems with uncompressing the the ods file. I will look a bit
deeper into it when I have some more time.

Regards,
TL
_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

Muthiah Annamalai-3
Tribo Laboy wrote:

> Hello.
>
> Is this anywhere close to what you are looking for?
>
> http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=18222&objectType=file
>
> I confirmed it works under MATLAB, but under Octave on WinXP I Have
> some problems with uncompressing the the ods file. I will look a bit
> deeper into it when I have some more time.
>
> Regards,
> TL
>  
It looks interesting, GPL'ed m-file code. Relies on xmlread() which is
in octave-forge
toolbox I think.

Also the problem with ODF I suspect its huge to cover all bases, and any
implementation
is going to be a broken subset. Writing a huge matrix in ascii and
putting that into a large
XML file and zipping it up is not my idea of a nice matrix format.

Best method was suggested earlier; csv read/write. Octave loads CSV's
nicely.

-Muthu


_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

Michael Goffioul
In reply to this post by Tribo Laboy
On Jan 25, 2008 9:25 AM, Tribo Laboy <[hidden email]> wrote:
> Hello.
>
> Is this anywhere close to what you are looking for?
>
> http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=18222&objectType=file
>
> I confirmed it works under MATLAB, but under Octave on WinXP I Have
> some problems with uncompressing the the ods file. I will look a bit
> deeper into it when I have some more time.

I see 2 potential problems:
1) "unzip": the function unzip.m relies on the unzip.exe utility, so you need
it somewhere in your PATH (for instance system("unzip.exe --help") should
succeed)
2) "xmlread": you need an AML toolbox for octave

Michael.
_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

Mats Hedlund
In reply to this post by Muthiah Annamalai-3
Muthiah Annamalai wrote:

> <div class="moz-text-flowed" style="font-family: -moz-fixed">Tribo
> Laboy wrote:
>> Hello.
>>
>> Is this anywhere close to what you are looking for?
>>
>> http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=18222&objectType=file
>>
>>
>> I confirmed it works under MATLAB, but under Octave on WinXP I Have
>> some problems with uncompressing the the ods file. I will look a bit
>> deeper into it when I have some more time.
>>
>> Regards,
>> TL
>>  
> It looks interesting, GPL'ed m-file code. Relies on xmlread() which is
> in octave-forge
> toolbox I think.
>
> Also the problem with ODF I suspect its huge to cover all bases, and
> any implementation
> is going to be a broken subset. Writing a huge matrix in ascii and
> putting that into a large
> XML file and zipping it up is not my idea of a nice matrix format.
>
> Best method was suggested earlier; csv read/write. Octave loads CSV's
> nicely.
Sure, numbers can be dealt with but there are two missing
functionalities with CSV:
1. can not deal with strings (for variable names, headers etc)
2. can not read/write data to/from a specific sheet in a ODS file

In my mind that's all what would be needed for dealing with ODS formats
from a pragmatic standpoint. Looks like the m-file referred to is
dealing with the read part. Could be a good starting point for adding
writing capabilities. I'll give it a spin.
/Mats


>
> -Muthu
>
>
>
> </div>

_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: ODF spreadsheets

kensmith
On Friday 25 January 2008 15:27, Mats Hedlund wrote:
[...]
> > Best method was suggested earlier; csv read/write. Octave loads
> > CSV's nicely.

You can also write cvs files line by line with code.  This lets you
create a CVS file that is different from how the data is stored in
Octave.


> Sure, numbers can be dealt with but there are two missing
> functionalities with CSV:
> 1. can not deal with strings (for variable names, headers etc)

"Width","Depth"
1,2
3,4
5,6

Works in OpenOffice's spread sheet.

> 2. can not read/write data to/from a specific sheet in a ODS file
>
> In my mind that's all what would be needed for dealing with ODS
> formats from a pragmatic standpoint. Looks like the m-file referred
> to is dealing with the read part. Could be a good starting point for
> adding writing capabilities. I'll give it a spin.
> /Mats
>
> > -Muthu
> >
> >
> >
> > </div>
>
> _______________________________________________
> Help-octave mailing list
> [hidden email]
> https://www.cae.wisc.edu/mailman/listinfo/help-octave

--
[hidden email]
_______________________________________________
Help-octave mailing list
[hidden email]
https://www.cae.wisc.edu/mailman/listinfo/help-octave