انتقل إلى المحتوى

قالب:Graph:Population history/شرح

من ويكيبيديا، الموسوعة الحرة

This graph's main version resides at mediawiki Template:Graph:Population_history. Please make all the changes there and copy it everywhere else (until the copying is automated)

استعمال[عدل]

{{Graph:Population history
| debug = 
| width = 
| height = 
| table = 
| values = 
| 1 = 
| filter = 
| atable = 
| avalues = 
| scale = 
| max = 
| orient = 
| color = 
| interpolate = 
| title = 
}}
{{Graph:Population history|Q84}}
Show London's population history from Wikidata
{{Graph:Population history

| table=Wikidata/St.Petersburg.tab
| atable=Original/St.Petersburg population annotations.tab}}
Show population of St.Petersburg from the table on Commons, with annotations

Inserts a graph with the population history for the given city.

وسائط القالب[تحرير بيانات القالب]

هذا القالب يفضل التنسيق الرأسي للوسائط.

وسيطوصفنوعحالة
City Wikidata ID1

Wikidata ID of the city or region

غيابي
Q84
نصاختياري
Title of the data page on Commonstable

Data page name on Commons, without the Data: prefix. The table must contain "year" and "population" columns.

نصاختياري
Raw values for this graphvalues

Supply all values as a list of JSON objects: {"year":1980, "population":1000}, {"year":1984, "population":1045}, ...

غير معروفاختياري
Title of the annotations data page on Commonsatable

Data page name on Commons, without the Data: prefix. The table must contain "year" column, and optional "text" and "color" columns.

نصاختياري
Raw annotation valuesavalues

Supply all annotation values as a list of JSON objects: {"year":1980, "text":"Big event"}, ...

غير معروفاختياري
Filter expressionfilter

Optionally, filter the data with an expression, e.g. datum.year >= 1900 && datum.year < 2000

غير معروفاختياري
Graph colorcolor

Shade with which to highlight the data in the chart

غيابي
#00f
مثال
#f00
نصاختياري
Interpolateinterpolate

How data points should be connected, e.g. linear, step-before, step-after, basis, basis-open, cardinal, cardinal-open, monotone

غيابي
monotone
مثال
linear
نصاختياري
Graph scalescale

Scaling could be one of these: linear, log, pow, sqrt, quantile, quantize, and threshold

غيابي
linear
مثال
log
نصاختياري
Maximum Y value axismax

This optional value might be useful to align multiple graphs side-by-side

غيابي
Automatically scaled to the data.
مثال
10000
رقماختياري
Widthwidth

Width for the chart in pixels, if different from the default.

غيابي
400
رقماختياري
Heightheight

Height for the chart in pixels, if different from the default.

غيابي
200
رقماختياري