multOf()

Gets a multiple of a number that approximates another number.

This function is valid in v2.8.0 to v2.14.0. This function has been downloaded 44 times.

Parameters

{number} factor
The number to get a multiple of.
{number} target
The number that the multiple of should approximate.
{boolean=} opt_roundOut Optional, Default:false
If true-ish the return value will be at least the same as target or further away from 0 than target, otherwise it will be target or closer to 0 than target.

Returns

{number}
A multiple of factor that approximates target. If opt_roundOut is true-ish this will be a value that is either target or a little further away from 0 than target. If opt_roundOut is false-ish this will be a value that is either target or a little closer to 0 than target.