Q: Array of Structures [message #12057] |
Fri, 12 June 1998 00:00 |
Saeid.Zoonematkermani
Messages: 6 Registered: December 1997
|
Junior Member |
|
|
Hi,
The output of one of my applications is an anonymous structure. After a
long session, I would like to create an array ofthese structures. I have
tried the following unsuccessfully.
IDL> tmp = [str1, str2]
% Conflicting data structures: STR2,concatenation.
% Execution halted at: $MAIN$
I have also tried:
IDL> tmp=replicate(str1,2)
IDL> tmp(1)=str2
% Conflicting data structures: STR2,TMP.
% Execution halted at: $MAIN$
I have string tags in the structure and my first thought was that the
unequal string length from one structure to another is causing the
problem. This does not seem to be the case since I picked two structures
with identical lengths and the same error message popped up.
Since these structures are created inside the same application, all the
tags are the same and I had hoped there would be no problem with creating
the arrays after the processing. My work around has been to write a simple
procedure that assigns the tags individually for each array element.
I am sure I am missing some thing very simple but with the world cup going
on, my brain seems to be on vacation. Any help would be greatly
appreciated. I am using IDL Version 5.1 (MacOS PowerMac). Thanks in
advance,
- Saeid
--
Saeid Zoonematkermani
Dept. of Physics & Astronomy
State University of New York
Stony Brook, NY 11794-3800
EMail: Saeid.Zoonematkermani@sunysb.edu
Voice: (+1) (516) 632-8237 Fax: (+1) (516) 632-8742
|
|
|