Re: How to plot multiple charts and ho to round float to specific precision? [message #44968 is a reply to message #44858] |
Thu, 28 July 2005 08:46   |
James Kuyper
Messages: 425 Registered: March 2000
|
Senior Member |
|
|
liko2@o2.pl wrote:
> No, it has to be a value of variable, later used for a part of title of
> a chart. So it has to be exact value with only 2 digits after zero.
If the only thing you're going to do with the variable is print it as
part of a title of a chart, isn't it sufficient to know how to print it
with only 2 digits after zero? Are there any calculations you intend to
perform, where it's important to use the rounded value, rather than the
exact value, in those calculations? I've seen situations where
something like that was actually the right thing to do, but they're not
very common.
If you do actually need the value of the variable rounded, and not just
the display of the variable, then the expression you've already been
given does the job:
value = ROUND(100.0*x)/100.0
|
|
|