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

Home » Public Forums » archive » Working with lists
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Working with lists [message #84410] Mon, 03 June 2013 10:39
fgg is currently offline  fgg
Messages: 67
Registered: April 2010
Member
Hello,

I have a string array that looks like this (with the exception that the numbers actually vary from element to element):

str = replicate('1000 1000.1515 400 40', 10)

Is there a simple way to extract these numbers to a 4 by 10 array without using loops? I've tried the following, but it doesn't work:

str = strsplit(str, /extract)
array = str.ToArray(type='float')

% LIST::TOARRAY: Unable to convert to type FLOAT: Element 7
% Error occurred at: LIST::TOARRAY
% $MAIN$
% Execution halted at: $MAIN$

What's the problem with this?

Thanks!
[Message index]
 
Read Message
Previous Topic: Re: Use IDLanROI or not
Next Topic: Re: libGL error: failed to load driver: nouveau

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

Current Time: Wed Oct 08 20:14:08 PDT 2025

Total time taken to generate the page: 0.00177 seconds