Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rounding makes the pass/fail appear incorrect #229

Open
jamesnw opened this issue Dec 20, 2024 · 0 comments
Open

Rounding makes the pass/fail appear incorrect #229

jamesnw opened this issue Dec 20, 2024 · 0 comments

Comments

@jamesnw
Copy link
Contributor

jamesnw commented Dec 20, 2024

Example- https://www.oddcontrast.com/#hsl__hsl(196.31_8.1868~_39.763~)__hsl(299_44~_91.5~)

It has a ratio of 4.498..., which rounds to 4.5. 4.5 is displayed, but the pass/fail is determined based on the full number.

Some options-

  1. Pass/fail based on the rounded number instead of the full number, which gives less precision (but are they actually significant digits? Probably not)
  2. Display a "floor" instead of a rounded number, in which case the example would show 4.49. This maintains that the ratio is not actually passing, but the value is more incorrect.
  3. Catch cases where this happens, and show the ratio to more digits, and not round. Always correct, always in sync, but adds more variation to the ratio length.

I guess the question is - do we care more about the pass fail or the ratio being accurate? Or make it a bit more complex and go with option #3?

We may also want to always show 2 digits after the decimal. This doesn't solve this issue, but would make the design more stable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant