Page 1 of 1

Decimal values

PostPosted: Sun Nov 18, 2018 12:14 pm
by mistertrade
Hi,
The value of some indicators appears with no decimal in the "Legend" section. I don't understand why.
For example, it's the case for 'MVA' indicator : The legend displays "MVA(Ger30.Close,20) : 11369" instead of ""MVA(Ger30.Close,20) : 11369,45" .

What can I do to solve this problem ?

Thank you,
Ron

Re: Decimal values

PostPosted: Wed Nov 21, 2018 9:29 am
by Apprentice
You can add this to somting like this in your indicator.
local precision = math.max(2, source:getPrecision());
OutputStreamName:setPrecision(precision);

or

OutputStreamName:setPrecision(10);
For 10 decimal places.

or

Simple simply request fix via the forum.