[Q:] How to use "xlswrite()" in Octave on Mac OS X Mavericks?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

[Q:] How to use "xlswrite()" in Octave on Mac OS X Mavericks?

TAISO, Renpoo
Hi there!
I'm new to here, and my name is Renpoo.

I'm a norvice user of Octave for a few months, and want to do some
signal processing job for a project. In the proj., I've already borrowed
some programs from my colleague and those codes are using the structured
data to contain every kind of resulting parameters.

I want to examine these resulting data in the Excel, since it is too
much amount and hard to examine in the "Workspace" window.

But the output command "xlswrite()" cannot work well with Octave 3.8.0
(GUI) on Mavericks.
If I want to use it, first of all, I have to install Java package, but I
can't, even though my Mac had already been installed the Java 1.6.0. as
Java Virtual Machine.

So, what should I do?
Is there any way to use xlswrite() in Octave on my Mac?
Or, is there another method useful to display/write-to-file those
resulting (structured) data?

Thanks in advance,
Renpoo


_______________________________________________
Help-octave mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: [Q:] How to use "xlswrite()" in Octave on Mac OS X Mavericks?

Philip Nienhuis
TAISO, Renpoo wrote
Hi there!
I'm new to here, and my name is Renpoo.

I'm a norvice user of Octave for a few months, and want to do some
signal processing job for a project. In the proj., I've already borrowed
some programs from my colleague and those codes are using the structured
data to contain every kind of resulting parameters.

I want to examine these resulting data in the Excel, since it is too
much amount and hard to examine in the "Workspace" window.

But the output command "xlswrite()" cannot work well with Octave 3.8.0
(GUI) on Mavericks.
If I want to use it, first of all, I have to install Java package, but I
can't, even though my Mac had already been installed the Java 1.6.0. as
Java Virtual Machine.

So, what should I do?
Is there any way to use xlswrite() in Octave on my Mac?
Or, is there another method useful to display/write-to-file those
resulting (structured) data?
(Disclaimer: I do not have a Mac so I'm not sure if the below will work *that* easily, so keep fingers crossed)

If you're OK with the newer .xlsx Excel format, you do not need Java.
E.g. LibreOffice can easily read & write .xlsx as well so you can inspect your data with it. Or with a recent enough Excel, if you insist.

Have you got the io package installed? The newest version is 2.2.3; that should work with Octave-3.8.x
If not:

more off
pkg install -forge -verbose io        ## Not sure if that'll work on OSX; maybe other ways are needed

So, if you have the io package installed *and loaded*, you should be able to write .xlsx files right away.
Just ignore the various messages the first time you use xlswrite.
Those messages just inform you what options ("interfaces") the io package has detected for spreadsheet I/O, it only searches the first time you invoke a function for spreadsheet I/O. (FYI, it should default to the "OCT interface", the one that doesn't require Java.)

Philip
Reply | Threaded
Open this post in threaded view
|

Re: [Q:] How to use "xlswrite()" in Octave on Mac OS X Mavericks?

TAISO, Renpoo
Thanks Philip,

But it causes the error message like below. (after following your
instruction)
> >> funcTest
> Checking requested interface(s):
> OCT*; (* = default interface)
> file /Users/renpoo/Projects/TheProj/Sounds/abc.xlsx couldn't be
> unpacked. Is it the proper file format?

The code for xlswrite() is like this.
> xlswrite( outputDataFileName, res, 'Sheet1', 'A1:XFD1048576', 'oct' );

Is it necessary to install another package?

Thanks in advance,
   Renpoo




(8/29/14, 19:37), Philip Nienhuis wrote:

> TAISO, Renpoo wrote
>> Hi there!
>> I'm new to here, and my name is Renpoo.
>>
>> I'm a norvice user of Octave for a few months, and want to do some
>> signal processing job for a project. In the proj., I've already borrowed
>> some programs from my colleague and those codes are using the structured
>> data to contain every kind of resulting parameters.
>>
>> I want to examine these resulting data in the Excel, since it is too
>> much amount and hard to examine in the "Workspace" window.
>>
>> But the output command "xlswrite()" cannot work well with Octave 3.8.0
>> (GUI) on Mavericks.
>> If I want to use it, first of all, I have to install Java package, but I
>> can't, even though my Mac had already been installed the Java 1.6.0. as
>> Java Virtual Machine.
>>
>> So, what should I do?
>> Is there any way to use xlswrite() in Octave on my Mac?
>> Or, is there another method useful to display/write-to-file those
>> resulting (structured) data?
> (Disclaimer: I do not have a Mac so I'm not sure if the below will work
> *that* easily, so keep fingers crossed)
>
> If you're OK with the newer .xlsx Excel format, you do not need Java.
> E.g. LibreOffice can easily read & write .xlsx as well so you can inspect
> your data with it. Or with a recent enough Excel, if you insist.
>
> Have you got the io package installed? The newest version is 2.2.3; that
> should work with Octave-3.8.x
> If not:
>
> more off
> pkg install -forge -verbose io        ## Not sure if that'll work on OSX;
> maybe other ways are needed
>
> So, if you have the io package installed *and loaded*, you should be able to
> write .xlsx files right away.
> Just ignore the various messages the first time you use xlswrite.
> Those messages just inform you what options ("interfaces") the io package
> has detected for spreadsheet I/O, it only searches the first time you invoke
> a function for spreadsheet I/O. (FYI, it should default to the "OCT
> interface", the one that doesn't require Java.)
>
> Philip
>
>
>
>
> --
> View this message in context: http://octave.1599824.n4.nabble.com/Q-How-to-use-xlswrite-in-Octave-on-Mac-OS-X-Mavericks-tp4666271p4666273.html
> Sent from the Octave - General mailing list archive at Nabble.com.
>
> _______________________________________________
> Help-octave mailing list
> [hidden email]
> https://lists.gnu.org/mailman/listinfo/help-octave


_______________________________________________
Help-octave mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: [Q:] How to use "xlswrite()" in Octave on Mac OS X Mavericks?

Philip Nienhuis
Please answer BELOW the text - makes it easier to follow and to answer.
Read on:

TAISO, Renpoo wrote
Thanks Philip,

But it causes the error message like below. (after following your
instruction)
> >> funcTest
> Checking requested interface(s):
> OCT*; (* = default interface)
That's good.

> file /Users/renpoo/Projects/TheProj/Sounds/abc.xlsx couldn't be
> unpacked. Is it the proper file format?

The code for xlswrite() is like this.
> xlswrite( outputDataFileName, res, 'Sheet1', 'A1:XFD1048576', 'oct' );
A1:XFD1048576 is an enormous array......(1048576 rows X 16384 columns).
You can simply specify an empty string ('', two consecutive single or double quotes)

And I think you may not need to specify "oct", you can leave the last two parameters altogether and it should just work.

Is it necessary to install another package?
I don't think so.

The unpack error points to a different problem.
Can you make an .xlsx file with Excel with some random data or so and try to
1. Read it with Octave, using xlsread
2. Add another sheet to it with xlswrite?

Philip
Reply | Threaded
Open this post in threaded view
|

Re: [Q:] How to use "xlswrite()" in Octave on Mac OS X Mavericks?

TAISO, Renpoo
I got it!!
Thanks Philip!!!


There were
   1. Mistake in replacing string for the output filename.
   2. Implement errors in original codes.


But now, I can see the resulting data cells in Excel!
Thanks a lot!

   Renpoo




(8/30/14, 0:14), Philip Nienhuis wrote:

> Please answer BELOW the text - makes it easier to follow and to answer.
> Read on:
>
>
> TAISO, Renpoo wrote
>> Thanks Philip,
>>
>> But it causes the error message like below. (after following your
>> instruction)
>>>>> funcTest
>>> Checking requested interface(s):
>>> OCT*; (* = default interface)
> That's good.
>
>
>>> file /Users/renpoo/Projects/TheProj/Sounds/abc.xlsx couldn't be
>>> unpacked. Is it the proper file format?
>> The code for xlswrite() is like this.
>>> xlswrite( outputDataFileName, res, 'Sheet1', 'A1:XFD1048576', 'oct' );
> A1:XFD1048576 is an enormous array......(1048576 rows X 16384 columns).
> You can simply specify an empty string ('', two consecutive single or double
> quotes)
>
> And I think you may not need to specify "oct", you can leave the last two
> parameters altogether and it should just work.
>
>
>> Is it necessary to install another package?
> I don't think so.
>
> The unpack error points to a different problem.
> Can you make an .xlsx file with Excel with some random data or so and try to
> 1. Read it with Octave, using xlsread
> 2. Add another sheet to it with xlswrite?
>
> Philip
>
>
>
>
> --
> View this message in context: http://octave.1599824.n4.nabble.com/Q-How-to-use-xlswrite-in-Octave-on-Mac-OS-X-Mavericks-tp4666271p4666278.html
> Sent from the Octave - General mailing list archive at Nabble.com.
>
> _______________________________________________
> Help-octave mailing list
> [hidden email]
> https://lists.gnu.org/mailman/listinfo/help-octave


_______________________________________________
Help-octave mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: [Q:] How to use "xlswrite()" in Octave on Mac OS X Mavericks?

Philip Nienhuis
TAISO, Renpoo wrote
I got it!!
Thanks Philip!!!


There were
   1. Mistake in replacing string for the output filename.
   2. Implement errors in original codes.


But now, I can see the resulting data cells in Excel!
(Hmmm, my remark about top-posting didn't trickle down .... :-) )

Thanks for your feedback - on my side I'm pleased to know that the io package seems to works fine on OSX as well.
(I have no Mac available for testing the io pkg, so I have to rely on occasional info from OSX users)

Philip
Reply | Threaded
Open this post in threaded view
|

Re: [Q:] How to use "xlswrite()" in Octave on Mac OS X Mavericks?

TAISO, Renpoo
Sorry, Mr. Philip,

But your suggestions worked fine besides my bug fix.
Thnx!

   Renpoo




(8/30/14, 18:58), Philip Nienhuis wrote:

> TAISO, Renpoo wrote
>> I got it!!
>> Thanks Philip!!!
>>
>>
>> There were
>>     1. Mistake in replacing string for the output filename.
>>     2. Implement errors in original codes.
>>
>>
>> But now, I can see the resulting data cells in Excel!
> (Hmmm, my remark about top-posting didn't trickle down .... :-) )
>
> Thanks for your feedback - on my side I'm pleased to know that the io
> package seems to works fine on OSX as well.
> (I have no Mac available for testing the io pkg, so I have to rely on
> occasional info from OSX users)
>
> Philip
>
>
>
>
> --
> View this message in context: http://octave.1599824.n4.nabble.com/Q-How-to-use-xlswrite-in-Octave-on-Mac-OS-X-Mavericks-tp4666271p4666291.html
> Sent from the Octave - General mailing list archive at Nabble.com.
>
> _______________________________________________
> Help-octave mailing list
> [hidden email]
> https://lists.gnu.org/mailman/listinfo/help-octave


_______________________________________________
Help-octave mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-octave