Punchcard icon indicating copy to clipboard operation
Punchcard copied to clipboard

type:fix

Open alemelis opened this issue 7 years ago • 1 comments

fixed the issue with binary matrices (only 0s and 1s) by adding the check to hi and lo

explanation: when the .csv contains a binary matrix as this one

,1,2,3
Monday,0,1,0,0
Tuesday,0,0,0
Wednesday,0,1,1
Thursday,0,0,0
Friday,0,1,0
Saturday,1,0,0
Sunday,1,1,1

the script fails at finding two different values for hi and lo variables. This in turn causes a ZeroDivisionError: float division by zero during execution.

I fixed this issue by forcing lo=0. in the case it has the same value of hi.

alemelis avatar Mar 25 '17 12:03 alemelis