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

Home » Public Forums » archive » Re: creating variables in a FOR loop
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 variables in a FOR loop [message #79117 is a reply to message #79116] Thu, 02 February 2012 06:57 Go to previous message
Rohit Deshpande is currently offline  Rohit Deshpande
Messages: 6
Registered: June 2011
Junior Member
Sorry, I mean line 5 and not 6.

Thanks,

On Feb 2, 9:53 am, singlebinary <singlebin...@gmail.com> wrote:
> Hello All,
>
> I would like to read in 6 files and associate 6 variables in which to
> store the information. In the code below, I like to create variables
> which names, "m_0, im_1 and so on. However, I get s 'Syntax error' in
> line 6. Please help! Thanks in advance.
>
> 1    PRO CCFs
> 2           files=file_search('*.fits')
> 3           FOR i = 0, n_elements(files)-1 DO BEGIN
> 4               temp = i
> 5               'im_'+strtrim(temp,2) = mrdfits(files[i],0,h)
> 6           ENDFOR
> 7
> 8   END
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Coyote Library Update
Next Topic: ANOVA statistical analysis with IDL

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

Current Time: Wed Oct 08 17:32:38 PDT 2025

Total time taken to generate the page: 0.00512 seconds