Five financial ratios
Gross margin, receivables/revenue, operating cash/revenue, liabilities/assets and expenses/revenue. Missing inputs and zero denominators remain explicit; observed zero values are retained.
DATA EXPLORATION · LEARNING EXPERIMENT
24 fictional companies across two years. Clusters describe patterns; they are not tax-risk labels or violation predictions.
A within-year 0–100 scale, not a probability. Scores cannot be compared across years.
| Company | Sector | Cluster | Gross margin | Receivables / revenue | Cash / revenue | Liabilities / assets | Relative distance |
|---|
— means an undefined or missing observed ratio. Median imputation is used only for the model input. Filtering does not refit the model.
Gross margin, receivables/revenue, operating cash/revenue, liabilities/assets and expenses/revenue. Missing inputs and zero denominators remain explicit; observed zero values are retained.
Annual medians → StandardScaler → KMeans (k = 2/3/4, n_init = 20, seed = 42). PCA projects the same five standardized features to two dimensions; it is a display, not the clustering input.
All records are synthetic. There are no ground-truth risk labels, held-out predictive tests or a validated best k. Cluster numbers are arbitrary, fitted independently by year, and have no ranking meaning.
This newly authored example draws on financial-analysis learning topics. Source notebooks were reviewed, not reproduced with original business data. scikit-learn 1.7.2 · 48 synthetic records · generator seed 20261013.