Public
Edited
Oct 6, 2023
Insert cell
Insert cell
contrib2
X
time_2002
Y
Valeur
Color
Pays
Size
Facet X
Facet Y
Mark
line
Type Chart, then Shift-Enter. Ctrl-space for more options.

Insert cell
Plot.plot({
color: { legend: true },
marks: [
Plot.lineY(contrib2, {
x: "time_2002",
y: "Valeur",
stroke: "Pays",
tip: true
})
]
})
Insert cell
Plot.plot({
color: { legend: true },
marks: [
Plot.frame({ strokeOpacity: 0.1 }),
Plot.barY(contrib2, {
fy: "pays",
x: "time_2011",
y: "value",
fill: "type",
tip: true
}),
Plot.ruleY([0])
]
})
Insert cell
contrib2
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
contrib_france
Type SQL, then Shift-Enter. Ctrl-space for more options.

Insert cell
contrib2 = db.query(`SELECT * FROM contrib_france WHERE type = 'gaz'`)
Insert cell
url_data = "https://minio.lab.sspcloud.fr/projet-shiny-conj/inflation/onglet9.parquet"
Insert cell
db = {
const configuredClient = await DuckDBClient.of();

await configuredClient.query(`
CREATE VIEW contrib_france AS
SELECT * FROM read_parquet('${url_data}') ;
`);
return configuredClient
}
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