parseDecimalCoeff

fnlong parseDecimalCoeff(scope const(char)[] text, ubyte scale) @safe

Parses a decimal string into a coefficient at the given scale. Exact: trailing digits beyond scale that are nonzero throw.

Parameters

textthe decimal text (e.g. "19.99")
scalethe target fraction digits

Returns

the coefficient (1999 for "19.99" at scale 2).

Throws

DataFrameException on malformed text, inexact rescale,

or overflow.