Research talk:GuidedTour usage
Add topicWork log
[edit]Monday, February 10th
[edit]Matt and [Steven] want to know how many wikis have local guided tours. The easiest way to get this should be a script to search the MediaWiki namespace for 'guidedtour' etc. on all wikis where it is enabled.
So, I have two goals:
- Determine which Wikis have had a minimum amount of GuidedTour usage
- Quantify the GuidedTour usage per Wiki
It would be nice if I could draw some attention to some of the most used tours as well.
I can make use of Schema:GuidedTour to identify use of GuidedTours. I'd like to minimize counting tours that were never used. I think that making sure that at least two users registered tour events should be a pretty good way to filter.
OK. So query time. This should be relatively straightforward.
SELECT wiki, COUNT(*)
FROM (
SELECT
wiki,
event_tourName,
COUNT(distinct event_userId) AS users
FROM GuidedTour_5222838
GROUP BY 1,2
) as wiki_tour_users
WHERE users >= 2
GROUP BY 1;
result
|
---|
+--------------+----------+ | wiki | COUNT(*) | +--------------+----------+ | astwiki | 1 | | cawiki | 7 | | dewiki | 3 | | enwiki | 16 | | frwiki | 3 | | hewiki | 1 | | itwiki | 2 | | outreachwiki | 1 | | plwiki | 1 | | ruwiki | 1 | | svwiki | 1 | | testwiki | 5 | | ukwiki | 1 | | wiki | 6 | +--------------+----------+ 14 rows in set (45.64 sec) |
"testwiki" and "wiki" represent test environments and should probably be discounted. Therefor, it looks like 12 wikis have tours that were at least tested by more than one user. Just for curiosity, I dropped the constraint on that least two users need to use the tour to see how it changes the count.
result
|
---|
+-----------------+----------+ | wiki | COUNT(*) | +-----------------+----------+ | astwiki | 1 | | cawiki | 8 | | commonswiki | 1 | | dewiki | 3 | | enwiki | 16 | | eswiki | 1 | | fawiki | 1 | | frwiki | 3 | | hewiki | 1 | | itwiki | 3 | | kowiki | 1 | | mediawikiwiki | 2 | | mwlwiki | 1 | | outreachwiki | 2 | | plwiki | 1 | | ruwiki | 1 | | svwiki | 1 | | testwiki | 7 | | this_is_my_wiki | 1 | | ukwiki | 1 | | viwiki | 3 | | wiki | 8 | +-----------------+----------+ 22 rows in set (45.55 sec) |
There we get 19 wikis after removing apparent test wikis. --Halfak (WMF) (talk) 22:04, 10 February 2014 (UTC)
So, it sounds like most tours don't get logged. I'm going to need to figure out which wikis have tours some other way. It looks like I can search for all pages in ns=8 ("MediaWiki") that begin with "GuidedTour-tour-" and end with ".js". This will gather all of the "community created" tours, but it will also gather tours that aren't finished or otherwise don't work. That will have to be good enough.
Here's my list of tours with the extension enabled:
wikis
|
---|
|
Here's the query:
SELECT page_title FROM page WHERE page_namespace = 8 AND page_title LIKE 'Guidedtour-tour-%.js'
And the results all fancy formatted with links:
--Halfak (WMF) (talk) 23:12, 10 February 2014 (UTC)