Decimals to Fractions

nice Jørgen!

thing is, with python, it’s simple:

import rhinoscriptsyntax as rs
import fractions

decimal = .2158
fraction = fractions.Fraction(decimal)

print fraction

i did this one a while back which rounds to nearest 1/16 (or 1/8 or 1/32 etc)

Dimensions help - python

the problem, for me at least, is i’m now wanting to do some dimensioning via grasshopper except i’m on mac and mac grasshopper doesn’t have python :wink:

1 Like