Skip to content
Snippets Groups Projects
Commit b2088028 authored by Benoît Courty's avatar Benoît Courty Committed by benoit-cty
Browse files

update Dorine

parent ec21dcc7
No related branches found
No related tags found
1 merge request!6Ajout de la section Education
......@@ -142,9 +142,9 @@ export function plot_map(
}
/*Carte de l'effectif des établissements supérieurs*/
let hovertemplate =
const hovertemplate =
"%{customdata.libelle_commune}<br>Statut : %{customdata.secteur_public_prive_libe}<br>%{customdata.type_d_etablissement}<br>Effectif : %{customdata.effectifs}<extra></extra>"
let color = dataEducation.etablissements_superieur.map((d) =>
const color = dataEducation.etablissements_superieur.map((d) =>
typeof d.effectifs === "undefined" || d.effectifs === null
? "grey"
: colorScaleEffectif(d.effectifs),
......@@ -192,9 +192,9 @@ export function plot_map(
customdata.ips_premier_et_second_prive_france,
]
const ips_premier_et_second_france_labels = [
"France max",
"France min",
"France moyenne",
"France IPS max",
"France IPS min",
"France IPS moyen",
]
const shapes_ips_prive_france = ips_premier_et_second_prive_france.map(
(ips) => ({
......@@ -204,8 +204,8 @@ export function plot_map(
x1: -10,
y1: ips,
line: {
color: "red",
width: 2,
color: "gray",
width: 1,
dash: "dot",
},
}),
......@@ -221,6 +221,11 @@ export function plot_map(
text: ips_premier_et_second_france_labels[
ips_premier_et_second_prive_france.indexOf(ips)
],
font: {
size: 10,
color: "gray",
},
align: "left",
}),
)
......@@ -238,23 +243,27 @@ export function plot_map(
x1: 0,
y1: ips,
line: {
color: "blue",
width: 2,
color: "gray",
width: 1,
dash: "dot",
},
}),
)
const annotations_public_france = ips_premier_et_second_public_france.map(
(ips) => ({
x: 15,
x: 18,
y: ips,
xref: "x",
yref: "y",
ax: 0,
ay: -10,
ay: 0,
text: ips_premier_et_second_france_labels[
ips_premier_et_second_public_france.indexOf(ips)
],
font: {
size: 10,
color: "gray",
},
}),
)
const shape_ips_public_circo = {
......@@ -266,7 +275,7 @@ export function plot_map(
line: {
color: "blue",
width: 2,
dash: "dash",
dash: "dot",
},
}
const shape_ips_prive_circo = {
......@@ -278,7 +287,7 @@ export function plot_map(
line: {
color: "red",
width: 2,
dash: "dash",
dash: "dot",
},
}
const annotations_prive_circo = {
......@@ -288,22 +297,33 @@ export function plot_map(
yref: "y",
ax: 0,
ay: -10,
text: "Moyenne circonscription",
text: "IPS moyen",
font: {
size: 10,
color: "red",
},
align: "left",
}
const annotations_public_circo = {
x: 10,
x: 17,
y: customdata.ips_premier_et_second_public_circo,
xref: "x",
yref: "y",
ax: 0,
ay: -10,
text: "Moyenne circonscription",
ay: 0,
text: "IPS moyen",
font: {
size: 10,
color: "blue",
textalign: "left",
},
position: "left",
}
const layout = {
title: "Répartition des établissements par IPS",
width: 600,
height: 400,
//title: "Répartition des établissements par IPS",
width: 800,
height: 500,
paper_bgcolor: "rgba(0,0,0,0)",
barmode: "overlay",
bargap: 0.0,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment