device-detector
device-detector copied to clipboard
Limiting list of device types
Hi -
I'm curious if there's any way to simplify or limit the list of device types? Most of our sites have very simple reporting needs. We would like to keep Smartphone, Desktop, Tablet; group Phablet into Tablet; group everything else into "Other". It's fine if it still tracks these on the back end but we just want to simplify the reporting for our clients. We manage about 50 sites and I can't think of a single client who needs to track usage from Cameras, Cars, TVs, Wearables, etc. It's cool that the system has that capability, but we just want to hide those options.
I'm also wondering if there's a place where we can learn how the determinations are made to categorize each visitor? What triggers Smartphone vs Phablet, etc? I took a quick skim through the code but could not find this information.
Thanks so much!
Ok, I found the regex in the mobiles.yml file, so I see where the categorizations are being made now.
I only did spot checking on the devices marked as "Phablet" but I think most people would consider to be "Phones" or "Smartphones" these days. Lumia 950 XL, HTC One Max... even iPhone 12, 12 Max, 13, 13 Max are being marked as "Phablets", but I think a vast majority of non-technical analytics users would expect those to all be called Phones. Big phones are kind of the norm now.
This forum comment from 2016 is saying the same thing: https://forum.matomo.org/t/consider-removing-phablet-as-a-segment/17647
Hi. in different years, phones of a certain screen size were considered a phablet.
in 2021 it is from 6.8 in 2019 it is from 6.5 in 2018 it is from 5.6 in 2017 it is from 5.5 in 2013 it is from 4.13
we can make a setting for phablets that would give out that it is a smartphone. is it necessary? @sgiehl
as for other types, it is difficult, for example, in the peripheral type there are telephones, scanners, mail terminals, refrigerators, printers, interactive panels, automatic gates, single-board computers.
I
@sanchezzzhak I wouldn't say we need to implement that into device detector. If someone is using device detector, he can simply map the types in his code.
@petertwise Are you using device detector directly, or is your request more related to the report Matomo is showing. For Matomo there might be other options to achieve merging Phablet and Smartphone into one...
Thanks for the responses. Yeah, I'm just looking for a way to present things more cleanly in Matomo reports... I don't think the underlying classification data needs to change. Any recommendations on where to start with that? Would I need to make my own fork of the device dectector plugin? Or is there a recommended way to override other than that?
@petertwise Sorry for the delayed answer. Its possible to overwrite the used device detector in Matomo. This is e.g. already done by the device detector cache plugin. See https://github.com/matomo-org/plugin-DeviceDetectorCache/blob/e7ddda820a6b45552b0f963f318338bf2ef87545/config/config.php#L6 I'll close the issue here, as this is nothing we will adjust in device detector