User Tools

Site Tools


oss-health-metrics:metrics:contributor-diversity

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
oss-health-metrics:metrics:contributor-diversity [2017/04/05 19:13]
abuhman [9. References to Academic Literature]
oss-health-metrics:metrics:contributor-diversity [2017/10/06 20:53] (current)
GeorgLink fixed link
Line 1: Line 1:
 ====== Contributor Diversity ====== ====== Contributor Diversity ======
-===== 1. Acronym ===== 
  
- +Page permanently moved to 
-===== 2. Alternate Names ===== +https://github.com/​chaoss/​metrics/​blob/​master/​activity-metrics/​contributor-diversity.md
- +
-===== 3. Classification ===== +
-Community Health +
- +
-===== 4. Description ===== +
-Ratio of contributors from a single company over all contributors +
-Also described asMaintainers from different companiesDiversity of contributor ​affiliation. +
- +
-==== Visualization ==== +
- +
-==== Interpretation ==== +
- +
- +
-===== 5. Known Implementations ===== +
- +
-===== 6. Data Source ===== +
-GHTorrent Database +
- +
-===== 7. Pseudo Code/Query ===== +
-=== Total number of organizations by project making pull requests (approved or not): === +
- +
- SELECT count(distinct org_id) as num_organizations,​ projects.name as project_name,​ url +
- FROM +
- organization_members +
-     join users on organization_members.user_id = users.id +
-     join pull_request_history on pull_request_history.actor_id = users.id +
-     join pull_requests on pull_request_history.pull_request_id = pull_requests.id +
-     join projects on pull_requests.base_repo_id = projects.id +
- WHERE pull_request_history.action = '​opened'​ +
- group by projects.id +
- +
-=== Alternately,​ using the "​company"​ field in the users table instead of the organization:​ === +
- +
- SELECT count(distinct company) as num_companies,​ projects.name as project_name,​ url +
- FROM +
-     users +
-     join pull_request_history on pull_request_history.actor_id = users.id +
-     join pull_requests on pull_request_history.pull_request_id = pull_requests.id +
-     join projects on pull_requests.base_repo_id = projects.id +
- WHERE pull_request_history.action = '​opened'​  +
- GROUP BY projects.id +
-  +
-=== Number of organizations by project making pull requests that are approved: === +
- +
- SELECT count(distinct org_id) as num_organizations,​ projects.name as project_name,​ url +
- FROM +
- organization_members +
-     join users on organization_members.user_id = users.id +
-     join pull_request_history on pull_request_history.actor_id = users.id +
-     join pull_requests on pull_request_history.pull_request_id = pull_requests.id +
-     join projects on pull_requests.base_repo_id = projects.id +
- WHERE pull_request_history.action = '​opened'​ +
- AND pull_requests.id in +
-     (SELECT pull_request_id  +
- from pull_request_history +
- where action = '​merged'​) +
- group by projects.id +
- +
-===== 8. Data Exchange Format ===== +
- +
- +
-===== 9. References to Academic Literature ===== +
- +
- +
-===== 10. Internet References ===== +
-Links to websites that add value to the understanding of the metric. +
- +
-===== 11. Contributors ===== +
-Authors of the metric page and authors who made significant changes.+
oss-health-metrics/metrics/contributor-diversity.1491419619.txt.gz · Last modified: 2017/04/05 19:13 by abuhman