Reputation: 3
When I type the instruction
gnuplot>plot "cbr_delay"
in the terminal,the system show error as follows
0.100000 0.038706
^
"cbr_delay", line 1: invalid command
the file cbr_delay is shown
0.100000 0.038706
0.108000 0.038706
0.116000 0.038706
0.124000 0.038706
0.132000 0.038706
0.140000 0.038706
0.148000 0.038706
0.156000 0.038706
0.164000 0.038706
0.172000 0.038706
0.180000 0.038706
0.188000 0.038706
0.196000 0.038706
0.204000 0.038706
0.212000 0.038706
0.220000 0.038706
0.228000 0.038706
0.236000 0.038706
0.244000 0.038706
0.252000 0.038706
what can i do to avoid the error?
Upvotes: 0
Views: 112
Reputation: 309929
It looks to me like you're typing that in exactly which your shell interprets as:
gnuplot cbr_delay > plot
What this means to the shell is that gnuplot should run the script cbr_delay and put the standard output stream in a file called "plot". You could test this by looking for a file called "plot" in the current directory.
What you want to do is first get to the gnuplot prompt by simply typing gnuplot
. Then you can type in your gnuplot commands:
gnuplot #enter gnuplot
#at this point, you should see a gnuplot prompt which looks like "gnuplot>"
#now enter your gnuplot command
plot "cbr_delay"
Upvotes: 1