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

Home » Public Forums » archive » Re: Printing in one line
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: Printing in one line [message #70449] Mon, 12 April 2010 20:45 Go to previous message
Ive Goncalves is currently offline  Ive Goncalves
Messages: 1
Registered: April 2010
Junior Member
On Apr 12, 5:05 pm, fgg <fabioguimaraesgoncal...@gmail.com> wrote:
> Hi,
>
> Here's an easy one. I have an array[5], y:
>
> IDL> print, y
> data = 1 2 3
>
> and I'd like to make IDL print:
>
> data = [1, 2, 3]
>
> When I try:
> IDL> m = n_elements(y)
> IDL> print, y[0:1], '[', y[2:m-2]+',', y[m-1] + ']'
>
> IDL prints:
> fabio =
> [
> 1, 2,
> 3]
>
> How can I get this result in just one line (instead of 4)?
>
> Thanks in advance,
> Fabio

Thanks a lot!
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: IMAGE_STATISTICS for 3D Array
Next Topic: IDL license costs in europe?

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

Current Time: Wed Oct 08 18:21:17 PDT 2025

Total time taken to generate the page: 0.00658 seconds