Hi Lu, For the LIST command, you can name a file yes? LIST/FILE=mydata.dat[/qualifiers] var The documentation for LIST shows qualifiers that let you control the format of this file, such as /FORMAT=, /PRECISN, /NOHEADER, /NOROWHEADER, and see also /CLOBBER or /APPEND. For more general question of getting and using information about data and the state of Ferret, there are a few different answers. Some of the Ferret state is available in symbols, such as STAT*, which writes its output to the command line. Symbols are automatically set which contain the output of the latest STAT command, and these can be used in the script. yes? stat var yes? show symbol stat* yes? if ($stat_mean) LT 7 then plot/i=1:12 var And if such logic is not available, there is always the option of piping the output to a file. Once you have a script working, use unix pipe syntax, > ferret -script myscript.jnl >& ferret_output.out You would probably want to put a "cancel mode verify" command at it the start of myscript.jnl to get just the outputs from commands, or to capture the entire session with all the commands and their outputs, use "set mode verify" instead. Lu Wang wrote: Dear users, |