[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ns] Reading .tr




>Date: Wed, 22 Nov 2000 13:42:39 +0100
>From: Andrea Josi <[email protected]>
>X-Accept-Language: en
>MIME-Version: 1.0
>To: [email protected]
>Subject: [ns] Reading .tr
>Content-Transfer-Encoding: 7bit
>
>Hi everybody,
>not only i am a beginner in using NS, but also in editing TCL scripts,
>that's why i don't know how to read trace files:
>if in my tcl script i create a file out0.tr
>
>set f0 [open out0.tr w]
>
>and i then write on that file
>
>puts $f0 "$now [expr $bw0/$time*8/1000000]"
>
>(lines taken from Marc Greis' tutorial example4.tcl)
>
>where do i have to look for and what lines do i have to add to my tcl
>script
>to read out0.tr ? I would like to save the result of the simulation
>in a file, what must i do to do that ? (and what are the possible
>extensions
>of the file?)

when writing to the file, you are indeed saving simulation results to that file 
:); it is a plain text file so you can read it with an editor. You can also open 
it with xgraph who will display a graph bandwidth=f(time).


>In the particular case mentioned, i would like to view a series of lines
>showing
>the sampling instant and the corresponding bandwidth value.
>Thanks for your help,
>                                       Andrea.
>
>

Tarik