# 065. Bounce and exit measurement audit

**Question:** How do bounce and exit rates relate, and where are their recorded values unusual?

## Result

The largest computed metric is 0.2168 for productrelated_duration; the smallest is -0.2545 for exitrates. Metric: spearman_rho (Spearman correlation).

Correlation is descriptive. The source metrics summarize pages visited during an already completed session.

![Bounce and exit measurement audit](outputs/chart.png)

| feature | spearman_rho | absolute_rho | paired_rows |
| --- | --- | --- | --- |
| exitrates | -0.2545 | 0.2545 | 12330 |
| productrelated_duration | 0.2168 | 0.2168 | 12330 |
| administrative_duration | 0.164 | 0.164 | 12330 |
| bouncerates | -0.149 | 0.149 | 12330 |
| informational_duration | 0.1121 | 0.1121 | 12330 |

The chart shows 5 of 5 result rows; the table previews the first 5 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

Rate-range validation and rank associations with completed-session outcomes.

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

Clarify the analytics platform definitions before treating these fields as interchangeable.

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/065-bounce-and-exit-measurement-audit/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.
