Loading ...
Sorry, an error occurred while loading the content.
 

more on $Arith

Expand Messages
  • dr1zzt81
    HI, I am currently trying to do a dynamic range for my heatmap -ish graph in Plotticus. As part of that, I find the range of my data and want to subdivide it
    Message 1 of 2 , Oct 30, 2002
      HI,

      I am currently trying to do a dynamic range for my 'heatmap'-ish
      graph in Plotticus. As part of that, I find the range of my data and
      want to subdivide it lineraly.

      the problem is that my range is so large, that my number is in
      scientific notation. I _think_ that $arith does not know how to deal
      with numbers in scientific notation, since when i try to display the
      number, it shows me "$arith(@DATARANGE-@DATASTEP)" instead of some
      rather large number.
      Am I correct on my assumption, and if I am, is there any way to
      prevent ploticus from chaning my number into scientific notation?

      thanks for making this great program,

      Greg
    • Stephen C. Grubb
      Greg, I think you re correct. In some circumstances you end up with values in scientific notation, which then is not handled by $arith(). You can control the
      Message 2 of 2 , Oct 30, 2002
        Greg,
        I think you're correct. In some circumstances you end up with values in
        scientific notation, which then is not handled by $arith().

        You can control the floating point format of a ploticus variable by doing
        something like this:

        #set DATARANGE = $formatfloat( @DATARANGE, "%.f" )

        before the $arith() call. The second function arg is a printf-like format
        specifier.

        The next ploticus version will have an optional 2nd arg to $arith that
        lets you specify the result decimal format.

        -Steve


        On Wed, 30 Oct 2002, dr1zzt81 wrote:

        > HI,
        >
        > I am currently trying to do a dynamic range for my 'heatmap'-ish
        > graph in Plotticus. As part of that, I find the range of my data and
        > want to subdivide it lineraly.
        >
        > the problem is that my range is so large, that my number is in
        > scientific notation. I _think_ that $arith does not know how to deal
        > with numbers in scientific notation, since when i try to display the
        > number, it shows me "$arith(@DATARANGE-@DATASTEP)" instead of some
        > rather large number.
        > Am I correct on my assumption, and if I am, is there any way to
        > prevent ploticus from chaning my number into scientific notation?
        >
        > thanks for making this great program,
        >
        > Greg
        >
        >
        >
        >
        > To unsubscribe from this group, send an email to:
        > ploticus-unsubscribe@yahoogroups.com
        >
        >
        >
        > Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
        >
        >
        >


        Stephen C. Grubb scg@...
        Scientific Software Engineer, The Jackson Laboratory
        600 Main Street Bar Harbor, Maine 04609 USA
      Your message has been successfully submitted and would be delivered to recipients shortly.