Peut-on combiner plusieurs segments en même temps ?
Matomo’s segmentation architecture intentionally prevents simultaneous application of multiple distinct segments to maintain query performance and avoid complex logical conflicts that could produce misleading results. However, sophisticated segment composition techniques allow you to achieve complex visitor filtering through single, compound segments that combine multiple conditions.
When building compound segments, you construct logical relationships using AND and OR operators to create precisely targeted visitor groups. An AND condition requires visitors to meet all specified criteria simultaneously, such as « Country equals France AND Device Type equals Desktop, » which identifies French desktop users exclusively. OR conditions broaden your scope by including visitors who meet any of the specified criteria, such as « Referrer Type equals Search Engine OR Referrer Type equals Social Network, » capturing visitors from both organic search and social media channels.
Advanced segment construction supports nested conditions and exclusion logic, enabling highly sophisticated visitor definitions. For example, you might create a segment for « (Country equals United States OR Country equals Canada) AND Device Type equals Mobile AND NOT (Referrer contains ‘spam’), » which targets North American mobile users while excluding known spam referrers.
The segment comparison feature provides analytical value by allowing you to visually compare performance metrics between two segments side-by-side. Access this functionality through the comparison icon (typically represented by overlapping circles) located adjacent to the segment selector. This feature generates split reports showing how different visitor groups perform across all metrics, enabling data-driven insights about user behavior variations.
Performance Consideration: Complex compound segments with multiple OR conditions or broad exclusion rules can significantly impact report generation speed, particularly on large datasets. Test segment performance on limited date ranges before applying them to extensive historical periods. Consider breaking extremely complex segments into multiple simpler segments when performance becomes problematic.
Enterprise analytics teams should document segment logic clearly, as compound segments can become difficult to interpret over time. Establish naming conventions that reflect the underlying conditions, such as « US-CA_Mobile_NoSpam » for the example above, ensuring team members understand segment definitions without examining the underlying configuration.
Have some questions ? We have your solution