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

Home » Public Forums » archive » Array subscript for VECTOR must have same size as source expression
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Array subscript for VECTOR must have same size as source expression [message #76661] Fri, 24 June 2011 08:27 Go to previous message
Rohit Deshpande is currently offline  Rohit Deshpande
Messages: 6
Registered: June 2011
Junior Member
Hello Everyone,

I am a beginner in IDL and I have been working on a project. I explain
it below:

1. The Idea: Read a bunch of FITS files in IDL. They have structure so
I use MRDFITS. I would like to read each one of them in a separate
variable and plot them. Given that each file has X by Y dimension,
where X is always = 19 while Y changes but is mostly 1636.

2. The Code:

im = fltarr(n)
all_barytimes = dblarr(19,4000)
all_normflux = dblarr(19,4000)

FOR i = 0, n-1 DO BEGIN
; where filenames are the list of fits files I am reading
it.
im = mrdfits(file+'raw_test/'+string(filenames[i]),1,head)
all_barytimes[i,*] = im.BARYTIME
all_normflux[i,*] = im.AP_CORR_FLUX
ENDFOR

3. The Error:

IDL> lcs1
% READCOL: 21 valid lines read
MRDFITS: Binary table. 19 columns by 1639 rows.
% Array subscript for ALL_BARYTIMES must have same size as source
expression.
% Execution halted at: LCS1

Please let me know how to make it work.

Thanks!
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: "gridPositions" not work correct with "Z" device?
Next Topic: Latitude longitude and Image Navigation

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

Current Time: Wed Oct 08 15:11:24 PDT 2025

Total time taken to generate the page: 0.00375 seconds