doepy icon indicating copy to clipboard operation
doepy copied to clipboard

Negative floats return incorrect table

Open wkew opened this issue 2 years ago • 1 comments

When generating a Latin hypercube sampling (simple or space filled), input factors with negative value levels return a table with incorrect values.

For example,

build.lhs(
{'a':[-1,-5],
'b':[-3,-6],
'c':[1,2]})

returns a table like (numbers truncated for display)

   a        b      c
 0.5     -1.9     1.0
-0.76    -0.78    1.95
-0.04    -2.14    1.43

where clearly the options for A and B are out of bounds for the provided levels, whereas c is correct.

Python 3.8.13 doepy version 0.0.1 installed from pip

wkew avatar Nov 03 '22 05:11 wkew

The order of the boundaries is important (minValue maxValue). Try:

build.lhs(
{'a':[-5,-1],
'b':[-6,-3],
'c':[1,2]})

gedeck avatar Jan 09 '23 15:01 gedeck