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

Home » Public Forums » archive » How to supress output from going to new 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: How to supress output from going to new line [message #91109 is a reply to message #91106] Thu, 04 June 2015 07:12 Go to previous messageGo to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Vaibhav Pant writes:

> I am trying to print some long integers, double values in a file using PRINTF command but in the file some values are pushed to next line. Does anyone has any idea how to suppress it from jumping to new line?
>
> IDL> openw,3,'test.txt'
> IDL> printf,3,10.d,9.d,10.d,10.d,10.d,10.d,20.098d,15.d,17.d,2.d, 18.d,34.d IDL> close,3
>
> ============================================================ =================
> OUTPUT
> 10.000000 9.0000000 10.000000 10.000000 10.000000
> 10.000000 20.098000 15.000000 17.000000 2.0000000
> 10.000000 9.0000000 10.000000 10.000000 10.000000
> 10.000000 20.098000 15.000000 17.000000 2.0000000
> 18.000000 34.000000
>
> ============================================================ =================
> After every 5 elements next elements jumps to a new line. I want all values to be in one line only.
> Any ideas?

Use a FORMAT statement and an appropriate WIDTH for your output.

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thue. ("Perhaps thou speakest truth.")
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Text output line too short, width = val not working
Next Topic: Vertical text orientation?

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

Current Time: Wed Oct 08 20:13:27 PDT 2025

Total time taken to generate the page: 0.00429 seconds