Related sparkline PR is here: https://github.com/davaxi/Sparkline/compare/master...matomo-org:multiple-series
-> html table (including actions table + support for subtables)
-> evolution graphs
-> bar graphs
(not pie graphs, since it's not possible to show multiple serieses)
(not sparklines since we'd have to color code different comparisons, which would be confusing w/ evolution graphs since they have their own colors)
-> row evolution/overlay/transitions/segmented visitor log (they display on comparison rows and parameters should change appropriate for the specific compared period/segment)
NOTE: there is one issue here when the table is too big. When there are too many rows,
maxNumRowsToHandleEvents blocks row actions from displaying. Since comparing multiplies the amount of rows, it can happen often.
After using feature for 1-2 hours here is below all the feedback I could think of. Looking forward to the next iterations and getting this beautiful feature in Matomo 3.11.0.
Click on the period to compare with June 2019.(maybe on hover on the calendar after Compare was checked)
April 2019(big white block with close icon) while the calendar reads
May 2019(small grey box). We'd want the periods being compared to be listed next to each other. Maybe Dates + Segments blocks could be all on the sae line (and remove Expected a consistent display of the dates being compared "April 2019 vs May 2019" (sorted in chronological order).
How would the exporting of the comparison data work? Ideally when people click Export buttons we'd export the data from all the compared periods. Haven't checked how the API output looks like currently in the branch? would it support our standard formats: JSON, XML, CSV, etc.
Comparing 2 days and 2 segments (the sparkline image + text is duplicated for each Segment being compared)
Expected it to display the 3 values (also the other 2 periods being compared at this part of the graph)
In the report table, the current date is not displayed in Grey like other compared elements:
Compare icon is missing next to "All Visits" when a segment is selected. So it seems not possible to compare an opened segment to "All Visits" segment.
Maybe the calendar hover color could also change from grey and black to lighter green and green, showing that we're selecting a different period?
Comparing segments failed here with error
The segment condition 'visitCount<' is not valid.).
Change periodbelow the evolution graph). So that we can see on a graph, the 2 months day by day. Same when comparing weeks or years or any period. this is eg. how GA works.
(+205%)data point in the reports on hover. Could we add the description help text that explains where the number is from, on hover on the tooltip? it currently can say eg.
100 visits represents Y of Y with Zand we could append a text would need to explain and give the numbers used to process ratio) eg. "this is an evolution of +229.5% compared between May 2019 (xyz visits) and June 2019 (100 visits)."
Data not displayed on Search Engines & Keywords page
some reports error eg. Pages Following a Site Search - demo2 reproduce url
Goal metrics are not displayed when compared (reproduce url
it should be prevented to add the same period/segment twice to the comparison eg (July used twice).:
tried paging through the sub-table in a custom report (reproduce url) and got error
Comparing segments/periods with subtables only works when the comparison idSubtables are supplied as well.
Cohorts report (reproduce url) fails with `Please specify a value for 'cohorts'. when comparing periods
Change period feature and some icons are a bit broken:
it's still important to display the row with the date range label, when we compare dates And segments at the same time. But when we only compare dates, or segments, then the rows can be compressed.
@diosmosis did quickly look through the code and left a few notes. Awesome feature and don't have many comments on the code so far :) will look again once finished.
fyi getting this warning:
/plugins/CoreVisualizations/JqplotDataGenerator/Evolution.php(192): Warning - Declaration of Piwik\Plugins\CoreVisualizations\JqplotDataGenerator\Evolution::initChartObjectData($dataTable, $visualization) should be compatible with Piwik\Plugins\CoreVisualizations\JqplotDataGenerator::initChartObjectData($dataTable, Piwik\Plugins\CoreVisualizations\JqplotDataGenerator\Chart $visualization) - Matomo 3.10.0
Maybe we could also add a new challenge to the Tour plugin to motivate a user to try a date comparison for example. You could add a challenge under
plugins/Tour/Engagement, register the challenge in
plugins/Tour/Engagement/Challenges.php and mark it as completed when eg compareDates parameter is set similar to here: https://github.com/matomo-org/matomo/blob/3.11.0-b2/plugins/Tour/Tour.php#L43-L57
The export URL doesn't include the comparison parameter by the looks
For the user experience of comparing a new segment. Reckon it is quite hard to know and to click on the small icon. Ideally we would improve this but not sure how to, do you maybe have ideas?
I actually found this a quite good solution without cluttering the UI etc. just the icon would maybe need to be changed.
How did you get this API response? Or is it in a test?
I'm not sure what you refer to how I got the value but I think you mean the metadata. I can get this eg like this when I click on export for any report and then select "with metadata". EG
I see, interesting. I don't know what that is :) I'll take a look at where it's coming from.
In API output, eg https://demo2.matomo.org/index.php?compare=1&compareDates%5B%5D=2019-08-01&comparePeriods%5B%5D=month&date=2019-09-17&expanded=1&filter_limit=10&format=XML&idSite=23&method=UserCountry.getContinent&module=API&period=month&token_auth=anonymous is the "idsubdatatable_in_db" needed? or should it be "idSubtable"?
It's necessary in order for subtables to work in comparison mode. When opening a subtable for a specific segment/period, combination, we have to know the idSubtable for the report that the comparison row is for, we can't sent the idSubtable for the original report.
@diosmosis it's just that the entry is usually called
idSubtable or so and not
Just checked it's usually
@tsteur Applied the review feedback, will fix the tests now.
@tsteur tests are passing, can give it another review now.