Graph Statistics
Appearance
A page to help show the structure of the graph using metrics and statistics. For similar pages reference:
Simple Metrics
ItemCount
Gives a count of all items in the Wikibase-instance. {{#if: Student (Q167) | Items used: Student (Q167) | }}
{{#if: instance of (P3) | Properties used: instance of (P3) | }}
{{#if:|
{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
PREFIX p: <https://graphit.ur.de/prop/>|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
PREFIX p: <https://graphit.ur.de/prop/>|}}}}{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
PREFIX q: <https://graphit.ur.de/prop/qualifier/>|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
PREFIX q: <https://graphit.ur.de/prop/qualifier/>|}}}}{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
PREFIX v: <https://graphit.ur.de/prop/statement/>|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
PREFIX v: <https://graphit.ur.de/prop/statement/>|}}}}{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
|}}}}
}}#defaultView:Table
PREFIX wd: <https://graphit.ur.de/entity>
PREFIX wdt: <https://graphit.ur.de/prop/direct/>
SELECT (COUNT(*) as ?items)
WHERE {
# items that have 0+ statements
?item wikibase:statements ?s.
MINUS{ ?item a wikibase:Property } # Filter out properties
MINUS{ ?item wdt:P3 wd:Q167 } # Filter out students
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
} LIMIT 25
Make inline
PropertyCount
Gives a count of all properties in the Wikibase-instance {{#if: | Items used: | }}
{{#if: | Properties used: | }}
{{#if:|
{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
PREFIX p: <https://graphit.ur.de/prop/>|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
PREFIX p: <https://graphit.ur.de/prop/>|}}}}{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
PREFIX q: <https://graphit.ur.de/prop/qualifier/>|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
PREFIX q: <https://graphit.ur.de/prop/qualifier/>|}}}}{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
PREFIX v: <https://graphit.ur.de/prop/statement/>|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
PREFIX v: <https://graphit.ur.de/prop/statement/>|}}}}{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
|}}}}
}}#defaultView:Table
PREFIX wd: <https://graphit.ur.de/entity>
PREFIX wdt: <https://graphit.ur.de/prop/direct/>
SELECT (COUNT(*) as ?property)
WHERE {
?property a wikibase:Property.
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
} LIMIT 28
Make inline
OutDegree of Item
Gives back the outdegree (= all edges going 'out of a node) of a specific item. {{#if: Radiosity (Q113) | Items used: Radiosity (Q113) | }}
{{#if: depends on (P1) | Properties used: depends on (P1) | }}
{{#if:|
{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
PREFIX p: <https://graphit.ur.de/prop/>|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
PREFIX p: <https://graphit.ur.de/prop/>|}}}}{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
PREFIX q: <https://graphit.ur.de/prop/qualifier/>|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
PREFIX q: <https://graphit.ur.de/prop/qualifier/>|}}}}{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
PREFIX v: <https://graphit.ur.de/prop/statement/>|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
PREFIX v: <https://graphit.ur.de/prop/statement/>|}}}}{{ safesubst:p{{ safesubst:#ifeq:|eq|1|2}}|{{ safesubst:p{{ safesubst:#ifeq:|
|1|2}}||}}|{{ safesubst:p{{ safesubst:#if:|1|2}}|
|}}}}
}}#defaultView:Table
PREFIX wd: <https://graphit.ur.de/entity/>
PREFIX wdt: <https://graphit.ur.de/prop/direct/>
Select ?item ?itemLabel (count(DISTINCT ?outItem) as ?outDegree)
WHERE {
BIND (wd:Q113 as ?item).
OPTIONAL {?item wdt:P1 ?outItem.}
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
group by ?item ?itemLabel LIMIT 10
Change harcoded item to parameter