PROJECT OVERVIEW
I built a rule-driven probability and conditional-logic calculator inside PewStats PRO. The tool lets users define analytical conditions, apply them to historical football data, and review how frequently the selected scenario occurred.
THE PROBLEM
A useful analytical calculator needs more than a percentage. Users must understand which records were evaluated, how conditions were combined, what happens when data is missing, and why a result changes after a filter is edited. The interface also has to protect against invalid or contradictory combinations.
RULE MODEL
I separated the calculation engine from the presentation layer. Each condition is represented as structured data with a metric, operator, threshold, scope, and logical relationship. The engine evaluates conditions consistently across the selected sample and returns both the final rate and the supporting counts used to calculate it.
TRANSPARENT RESULTS
The result area explains the selected sample, successful occurrences, total eligible records, and the final calculated probability. Empty samples and incomplete conditions receive explicit guidance instead of returning misleading zero values. Users can review the active rules before running the analysis and adjust them without rebuilding the entire configuration.
INTERFACE DESIGN
I designed the calculator around progressive disclosure. The page introduces the purpose of the tool, keeps primary inputs grouped, distinguishes the action that runs the analysis, and uses clear feedback for warnings and results. The layout remains usable on smaller screens, where controls stack and long labels wrap safely.
DATA AND VALIDATION
Inputs are normalized before evaluation, and the engine handles missing fields, incompatible metrics, boundary values, and repeated conditions. I verified representative scenarios manually against source records and used regression checks to protect existing rules when new analytical options were added.
OUTCOME
The calculator turns a complex conditional workflow into a repeatable user-facing feature. Its architecture keeps business rules testable and extendable, while the interface makes the sample and result understandable enough for users to validate the analysis themselves.