-
Notifications
You must be signed in to change notification settings - Fork 0
/
methodBox.js
21 lines (19 loc) · 862 Bytes
/
methodBox.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
const methodBoxTextConfig = {
ckmeans:
"Die unterschiedlich grossen Gruppen kommen durch ein statistisches Verfahren zustande, welches die Werte so in Gruppen einteilt, dass die Unterschiede zwischen den Regionen möglichst gut sichtbar werden (Jenks Natural Breaks).",
quantile:
"Die Gruppen wurden so gewählt, dass in jeder Gruppe möglichst gleich viele Werte vorhanden sind.",
equal:
"Die Gruppen wurden so gewählt, dass sie jeweils einen gleich grossen Bereich auf der Skala abdecken.",
custom: "Die Gruppen wurden manuell definiert.",
};
function getMethodBoxInfo(bucketType) {
const methodBoxText = methodBoxTextConfig[bucketType];
return {
text: methodBoxText || "",
article: process.env.METHOD_BOX_ARTICLE
? JSON.parse(process.env.METHOD_BOX_ARTICLE)
: null,
};
}
module.exports = { getMethodBoxInfo };