# 068. Browser conversion diagnostics

**Question:** Which browser categories warrant investigation of their purchase experience?

## Result

The largest computed metric is 0.1963 for 10.0; the smallest is 0.04762 for 3.0. Metric: rate (Purchase-session share).

Numeric browser codes are not mapped to invented names. Differences do not prove a browser defect.

![Browser conversion diagnostics](outputs/chart.png)

| browser | events | n | rate | wilson_lower | wilson_upper | median_exit_rate |
| --- | --- | --- | --- | --- | --- | --- |
| 1 | 365 | 2462 | 0.1483 | 0.1348 | 0.1628 | 0.02667 |
| 2 | 1223 | 7961 | 0.1536 | 0.1459 | 0.1617 | 0.025 |
| 3 | 5 | 105 | 0.04762 | 0.02051 | 0.1067 | 0.03279 |
| 4 | 130 | 736 | 0.1766 | 0.1508 | 0.2058 | 0.02399 |
| 5 | 86 | 467 | 0.1842 | 0.1516 | 0.2218 | 0.028 |
| 6 | 20 | 174 | 0.1149 | 0.07565 | 0.1709 | 0.0282 |
| 8 | 21 | 135 | 0.1556 | 0.1041 | 0.2261 | 0.03466 |
| 10 | 32 | 163 | 0.1963 | 0.1426 | 0.264 | 0.02222 |

The chart shows 8 of 8 result rows; the table previews the first 8 in the analysis-defined order. [Download the full result table](outputs/results.csv). Numerical values are computed from the source; missing results stay unavailable.

## Method

Conversion intervals among browser categories with at least 100 sessions.

The study uses shared source preparation and reusable statistical routines. Its specific transformations are in [analysis.py](analysis.py), and common model/evaluation code is in [portfolio/methods.py](../../portfolio/methods.py). The [notebook](analysis.ipynb) executes the study and displays the saved results.

## Decision and limitations

Prioritize browser QA using real session evidence, then control for visitor and traffic mix.

One observation is a completed session. End-of-session behavior cannot support an early-session prediction claim. PageValues is excluded from purchase models because it can encode downstream purchase information. Associations are not experiment results. 

Related studies may share observations or holdouts. These are focused analytical studies, not independent replications or deployed business systems. Any model refinements informed by these results need new untouched evaluation data. No commercial impact is inferred from an association or backtest.

## Reproduce

From the repository root, after installing `requirements.txt`:

```powershell
python projects/068-browser-conversion-diagnostics/analysis.py
```

Source data are downloaded automatically if absent. Original archives are retained unchanged and checked by SHA-256. The cleaned cache normalizes column names; field-specific changes are visible in [data preparation](../../portfolio/data.py). Runtime evidence is in [receipt.json](outputs/receipt.json).

## Source

[Online Shoppers Purchasing Intention](https://archive.ics.uci.edu/dataset/468/online+shoppers+purchasing+intention+dataset), Sakar and Kastro (2018). [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/). Source data are transformed and aggregated in this study. [Source provenance](../../data/provenance/shoppers.json) and [prepared-data audit](../../data/provenance/shoppers_prepared.json) record the downloaded files, field coverage and hashes.
