Forum Discussion

Khalid700's avatar
Khalid700
Copper Contributor
Jan 06, 2023

trying to find solution

Excuse me .. I have two columns of sizes (length and width) >> Data stock <<
I want to write in two other columns (length and width)
and the result appears in two other columns as (the closest length and width to the entered size)
based on the sizes of the existing stock
thanks all

  • mtarler's avatar
    mtarler
    Silver Contributor
    You want "closest" length and width but do not explain how YOU define "closest". For example if you have length & width of a rectangle 2 ways of comparing them could be perimeter or area or something like delta length + delta width or you may want to square those differences (like variances) so (delta length)^2 + (delta width)^2 or something else all together. While you are at it, you should consider 'tie breakers' so if the equation you use ends up with a tie do you just use either one or should you consider an alternative value (or values) to break the tie.