LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

mathscript formatting

Can anyone advise me how numbers in the MathScript Output Window can be formatted (i.e. to 'x' decimal places for instance).  The default output appears to be just 4 decimal places but I need to see 12 decimal places.

0 Kudos
Message 1 of 3
(2,178 Views)

Hi bunnykins,

 

If you have an indicator that is outputting decimals I'm guessing that your are using the data type double.  The data type double has approximately 16 decimal digits.  The limiting factor maybe the display format of your indicator.

 

mathscript.png 

 

Using this code the indicator displays 14 digits.  To change the number of digits displayed you can right-click on the indicators and select Display Format.... In this window you can edit the number of displayed digits.  You may also have to resize the indicator for it to fit all of the digits.

 

Regards,

Mike Altmann
Product R&D
NI
0 Kudos
Message 2 of 3
(2,147 Views)

Hello bunnykins,

 

You can type format long in the MathScript Window to see additional digits after the decimal point.  In addition, there is a dedicated MathScript forum if you wish to see other support questions.

 

Grant M.

Senior Software Engineer | LabVIEW Tablets | National Instruments

0 Kudos
Message 3 of 3
(2,142 Views)