comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Exporting matrices without filling blank space with zeros
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: Exporting matrices without filling blank space with zeros [message #67650] Wed, 19 August 2009 10:25
Jeff[2] is currently offline  Jeff[2]
Messages: 18
Registered: November 2007
Junior Member
On Aug 19, 1:25 pm, Spon II <christoph.b...@gmail.com> wrote:
> On Aug 19, 2:46 pm, Julio <julio.esque...@gmail.com> wrote:
>
>
>
>> I have several arrays with one column, but with different number of
>> lines. For example, arrays 1 and 2:
>
>> array1
>> 10
>> 30
>> 12
>> 34
>> 12
>
>> array2
>> 102
>> 34
>> 14
>
>> I want to put these arrays in one ASCII file or SYLK spreadsheet, like
>> this:
>
>> 10 102
>> 30 34
>> 12 14
>> 34
>> 12
>
>> I guess it must be easy, but I can't do that, once the output matrix
>> fills the blank spaces with zeros. How can I do that?
>
>> Best
>> Julio
>
> Hi Julio,
>
> If you use a string array as your output matrix, the zeroes should be
> gone, replaced by blank strings.
> Regards,
> Chris

Yes, when using string array the output matrix has no zeros, but the
real values are put in the same column. A already solved this problem
using PRITF with FORMAT option.
Thanks
Julio
Re: Exporting matrices without filling blank space with zeros [message #67653 is a reply to message #67650] Wed, 19 August 2009 09:25 Go to previous message
Spon is currently offline  Spon
Messages: 178
Registered: September 2007
Senior Member
On Aug 19, 2:46 pm, Julio <julio.esque...@gmail.com> wrote:
> I have several arrays with one column, but with different number of
> lines. For example, arrays 1 and 2:
>
> array1
> 10
> 30
> 12
> 34
> 12
>
> array2
> 102
> 34
> 14
>
> I want to put these arrays in one ASCII file or SYLK spreadsheet, like
> this:
>
> 10 102
> 30 34
> 12 14
> 34
> 12
>
> I guess it must be easy, but I can't do that, once the output matrix
> fills the blank spaces with zeros. How can I do that?
>
> Best
> Julio

Hi Julio,

If you use a string array as your output matrix, the zeroes should be
gone, replaced by blank strings.
Regards,
Chris
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: CHISQR_CVF question.
Next Topic: FITS to ascii spectra

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 20:04:59 PDT 2025

Total time taken to generate the page: 0.02956 seconds