matomo-org / matomo-org/matomo
[Bug] Ecommerce statistics - Abandoned cart visiors reference wrong
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 21.9k
- Forks
- 2.9k
- Avg merge
- 3d 3h
- Merged PRs (30d)
- 139
Description
### What happened?
In the ecommerce overview there is the statistic “Visits with Abandoned Cart” on the left. In addition to the value, there is an indication of the change in the selected period. This value doesn't seem to be correct. Likewise, when you mouse over, a help text is displayed that indicates the basis for the calculation.
For example, if I select the day March 9, 2024, there will be 968 visitors.
The development says 158.8% more visitors. The tooltip shows - 374 visitors for March 8, 2024. But if I select March 8, 2024 in the date field, it shows 1050 visitors.
Both times it seems to refer to the number of orders - i.e. not visitors with visitors to the previous period.
### What should happen?
In my opinion that would be correct
Visitors with abandoned shopping cart on March 9, 2024 = 968
Visitors with abandoned shopping cart on March 8, 2024 = 1050
Proportional change on March 9, 2024 of -7.81%
### How can this be reproduced?
The easiest way is to use the Matomo demo https://demo.matomo.cloud/
Click on Ecommerce - Overview
Selection date March 9, 2024

On the right are the values and the mouseover that shows the reference.
Change from the previous day refers to 374
Then selection of March 8, 2024

So here you can see that it refers to the orders. This value is namely 374.
But the 1050 would be correct.
### Matomo version
Matomo Demo
### PHP version
8
### Server operating system
Apache
### What browsers are you seeing the problem on?
Firefox, Chrome, Safari, Microsoft Edge
### Computer operating system
Linux
### Relevant log output
_No response_
### Validations
- [X] Read our [Contributing Guidelines](https://github.com/matomo-org/matomo/blob/5.x-dev/CONTRIBUTING.md).
- [X] Follow our [Security Policy](https://github.com/matomo-org/matomo/blob/5.x-dev/SECURITY.md).
- [X] Check that there isn't already an issue that reports the same bug to avoid creating duplicates.
- [X] The provided steps to reproduce is a [minimal reproducible](https://stackoverflow.com/help/minimal-reproducible-example) of the Bug.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in Ecommerce > Overview and reproduce the March 9 and March 8, 2024 comparison in the Matomo demo. Trace the calculation and tooltip for “Visits with Abandoned Cart”; done means the comparison uses visitor counts from the previous period and reports the expected proportional change of -7.81%.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- analytics
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100