**Data:**
* [MediaWiki Database](https://www.mediawiki.org/wiki/Manual:Database_layout): These tables exist for each individual wiki, e.g. for the English Wikipedia, for Wikimedia Commons. You can access them via [mysql](https://wikitech.wikimedia.org/wiki/Analytics/Data_access#MariaDB_replicas).
* [Eventlogging](https://wikitech.wikimedia.org/wiki/Analytics/Systems/EventLogging): Logs of how users interact with the UI. You can access them via [mysql](https://wikitech.wikimedia.org/wiki/Analytics/Systems/EventLogging#MariaDB) or [Hive](https://wikitech.wikimedia.org/wiki/Analytics/Systems/EventLogging#Hadoop_&_Hive).
* [Webrequest](https://wikitech.wikimedia.org/wiki/Analytics/Data_Lake/Traffic/Webrequest): The webrequest datasets contain logs of all the hits to the WMF's servers. They are records of how users consume Wikimedia contents. You can access them via [Hive](https://wikitech.wikimedia.org/wiki/Analytics/Systems/Cluster/Hive).
* [Data dumps](https://meta.wikimedia.org/wiki/Data_dumps): A complete copy of all Wikimedia wikis, in the form of wikitext source and metadata embedded in XML. A number of raw database tables in SQL form are also available. These snapshots are provided at the very least monthly and usually twice a month. Dump files are also available in various location on Labs & some Production servers.
More details about data access: https://wikitech.wikimedia.org/wiki/Analytics/Data_access
**Tools:**
* [Hadoop cluster](https://wikitech.wikimedia.org/wiki/Analytics/Data_access#Hadoop): Our storage system for large amounts of data. See also: https://wikitech.wikimedia.org/wiki/Analytics/Systems/Cluster. You can submit your query on stats machine, or [Hue](https://hue.wikimedia.org/).
* Mysql: There are multiple ways to access mysql database.
** Once ssh'd into stat1005 or stat1006: for mediawiki database, run `mysql -h analytics-store.eqiad.wmnet`, for event logging, run `mysql -h analytics-slave.eqiad.wmnet`, to open the mysql command line interface
** In R, install our internal ["wmf"](https://github.com/wikimedia/wikimedia-discovery-wmf/) package and use wmf::build_query() to execute queries and get that data into R. You can do this on stat1005, or on your local machine ([example](https://github.com/wikimedia-research/SDoC-Initial-Metrics/blob/master/T177356/queries/deleters.R#L1-L12)). Install wmf via `devtools::install_git('https://gerrit.wikimedia.org/r/wikimedia/discovery/wmf')`
** Use tools like [Sequel Pro](http://www.sequelpro.com/)
* [Quarry](https://quarry.wmflabs.org/): A public interface for querying a set of SQL replicas of the production MediaWiki databases. Various private information is redacted from these replicas. Also the machines running the queries are not super powerful.
* [PageView API](https://wikitech.wikimedia.org/wiki/Analytics/PageviewAPI): Public api allowing access to the pageview data on all wikis in a variety of ways. E.g. [Daily viewcounts for an article like “Albert Einstein”](https://wikimedia.org/api/rest_v1/metrics/pageviews/per-article/en.wikipedia/all-access/all-agents/Albert_Einstein/daily/2015100100/2015103100). This data can also be queried using Hadoop.
* Feel free to do the analysis with R/Python/whatever you are comfortable with. If you use R, see https://meta.wikimedia.org/wiki/Discovery/Analytics#Analysis_with_R for the internal packages we built.
**//You need to know what they are, their structures, how to operate within them, and how to get data out of them for analysis.//** So thorough knowledge is very important.
To get familiar with these data and tools, we want you to replicate the baseline metrics we computed for [Structure Data on Wikimedia Commons](https://commons.wikimedia.org/wiki/Commons:Structured_data) (SDoC). See the [original task](https://phabricator.wikimedia.org/T174519), [results](https://meta.wikimedia.org/wiki/Research:Baseline_Metrics_for_Structured_Data_on_Wikimedia_Commons) and [analysis codebase](https://github.com/wikimedia-research/SDoC-Initial-Metrics) for more information. The presentation of the results does not have to be the same, as long as it answer the question. This task will be split up into the following sub-tasks:
* T185365: File contributions by bots vs users
* T186575: File type and deletion metrics