|
From: Petr M. <mi...@ph...> - 2004-10-15 07:01:50
|
> > N = N + 1
> > filename = "run_" . N . ".dat"
> > print filename
> > run_4.dat
> >
> > I am not aware of any problems introduced by either feature,
> > but comments are welcome.
>
> I'm not sure if this one is really needed. I would rather like to
> have a builtin function "atof" to explicitly cast strings to
> numbers.
I like this, it is like in awk.
> I think the extra features patch can give parse errors. Consider
>
> x = "5"
> set label x, 7
I think that these problems may arise only if there is a "default" option
expected for a given value (like "font" option for "set term post", where
just a string is OK). But this can always be avoided by a particular
keyword.
> file = "input.dat"
> value = `some-command @file`
I would propose to ignore macro expansion in `blabla1` and
!blabla2
but allow them in
system('blabla2')
and in
value = execute('blabla1');
Where the execute() is a new command. The user could use what he wants.
> set label sprintf("foo %f %f",var1,var2)
I really prefer the sprintf() way as it is a function like in C & friends.
>> gnuplot> print sprintf("%i", 5.)
>> 0
>This example doesn't work in C either.
But it works in Octave and awk; I use it there to print an integer part of
the value. I would rather prefer an inteligent version that returns in the
above example 5.
> FOO = floor(FOO)
> "see man page for sprintf"
Well, "man floor" says that result of floor() and ceil() is also a double
value, so it does not help. Just in gnuplot it returns an integer.
---
PM
|