Filter Graph by Custom Variable

Is it possible to filter the visitors graph based on a custom variable from the tracker? I want to show an evolution graph of all the visits with a 70 value in the first custom variable slot. I tried this call


but got ‘No data for this graph.’

When I remove the filter_pattern I get a graph. I checked the piwik_log_visit table in the database and I have that value for visit records.

Yes it is possible with the use of segmentation: Segmentation - Compare segments of visitors - Analytics Platform - Matomo
Currently in the API only but soon in the INterface too!

Thanks. Will these stats keep with the archiving?

They will be processed the first time you ask for and then cached. However it will be pre-processed by archiving. You can do so, see [Segments] in the file config/global.ini.php for more info

Happy New Year! If you are still using Piwik and interested in the awesome new feature of “Creating a Custom Segment in Piwik and apply to reports in Real time!” we need YOUR help, with a little or big donation at:

This will allow to dynamically add or edit, a new set of rules for example “Show all visitors from USA and using Firefox and using Google”. This will be done via a simple to use interface. See screenshots and more info here:

We are crowd funding the future of Piwik and this feature in particular. With your help we can do it.