Public
Edited
Jun 1, 2023
Insert cell
Insert cell
annees = new Set(donsFM.map(d => d.dateAcquisition).sort())
Insert cell
graphiqueBarres = Plot.plot({
height: 800,
width: 1150,
marginLeft: 50,
marginRight: 10,
marginTop: 50,
marginBottom: 65,
x: {
domain: annees,
type: "band",
tickFormat: d => d.toString(),
tickRotate: -45,
//label: `${legendeGraphique} par années de ${selecteurIntervalleTemps[0]} à ${selecteurIntervalleTemps[1]}, catégorisés selon les sexes associés des artistes`,
label: "",
inset: 10,
},
y: {
//domain: [0, 200],
//label: `${legendeGraphique} (nombre)`,
label: "",
marginLeft: "20px",
grid: true
},
marks: [
Plot.rectY(donsFM, Plot.binX({y: "count"}, {x: "dateAcquisition", fill: "genreAssocie",
thresholds:60,order: ["Féminin", "Mixte"]}))
],
color: {
type: "categorical",
range: [bordeau, jaune],
legend: true,
},
style:{
backgroundColor: noir,
color: gris,
fontSize: "16px",
}
})
Insert cell
donsFM.filter(d => d.provenance.includes("Don de l’artiste"))
Insert cell
donsFM = oeuvresFemmesEtMixte.filter(d => d.numero.substr(0, 1) == "D")
Insert cell
donsF = oeuvresMacEtudiees.filter(d => d.genreAssocie == "Féminin" && d.numero.substr(0, 1) == "D" )
Insert cell
donsM = oeuvresMacEtudiees.filter(d => d.genreAssocie == "Mixte" && d.numero.substr(0, 1) == "D" )
Insert cell
Insert cell
oeuvresFemmesEtMixte = oeuvresMacEtudiees.filter(d => d.genreAssocie == "Féminin" || d.genreAssocie == "Mixte" )
Insert cell
import {oeuvresMacEtudiees} from "1cd6c83a4402c258"
Insert cell
import {provenance} from "1cd6c83a4402c258"
Insert cell
import {couleurs} from "26cecfbef9723965"
Insert cell
gris = couleurs[1]
Insert cell
bordeau = couleurs[2]
Insert cell
noir = couleurs[3]
Insert cell
jaune = couleurs[0]
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more