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

Home » Public Forums » archive » Re: creating multiple files
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: creating multiple files [message #47363 is a reply to message #47362] Mon, 06 February 2006 22:15 Go to previous messageGo to previous message
bressert@gmail.com is currently offline  bressert@gmail.com
Messages: 8
Registered: February 2006
Junior Member
Hello Dave,

Thank you for your quick reply and suggestions. I tried what you posted
with no luck. I think what I explained was not detailed enough. Here is
the part of the script that I'm working with.

==========Script============
;read the columns of the sundata.dat file into program
readcol, dialog_pickfile(), it, sundata, dm, sm

;create matrix of imported data
array = transpose([[it],[sundata],[dm],[sm]])

;array that expresses the total number of rows in it
i = findgen(size(it,/n_elements))

;index values where it[i] gt it[i+1], meaning a new file should be
created
index = [0,where(it[i] gt it[i+1])]
index = transpose(index)

;array that expresses the total number of rows in index
j = findgen(size(index,/n_elements))

;array that is created multiple times to print multiple files of
sun#.txt
sun"j" =
transpose([[it[index[j]:index[j+1]]],[sundata[index[j]:index [j+1]]],$
[dm[index[j]:index[j+1]]],[sm[index[j]:index[j+1]]]])

;file creation and printing
openw, lun, 'C:\sun"j".dat', /get_lun

printf, sun"j", index, format='(10i10)'

free_lun, lun

==========End of Script============

I just need to enter the parameters as you suggested in a way that
would work. Your website is very well done and informative. I have gone
there many times with promising results, thanks.

All the best,

Eli
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: creating multiple files
Next Topic: Re: cannt disable widget timer event?

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

Current Time: Fri Oct 10 01:00:46 PDT 2025

Total time taken to generate the page: 1.12078 seconds