Platform
Resources
Pricing
Sign in
Get started
Hongtao Hao
Workspace
Fork
Public
tutorials
By
Hongtao Hao
Edited
Mar 31, 2021
1 fork
10 stars
tutorials
Scatter plots
Tensorflow (neural network)
How to understand D3's paddingInner
Introduction
D3 practice, 2021-03-31
How to use CSS style sheets in Observable Notebooks
exercise
Explorable Data
How to differentiate between let, const, and var in JavaScript / Observable
Day 1 & Day 2, 25 Aug. & 26 Aug., 2020, Basic Commands
Insert cell
Insert cell
Insert cell
Insert cell
{
const
svg
=
d3
.
create
(
"svg"
)
.
attr
(
"width"
,
"500"
)
.
attr
(
"height"
,
"200"
)
.
attr
(
"id"
,
"svg"
)
;
let
rect
=
svg
.
append
(
"rect"
)
.
attr
(
"x"
,
"220"
)
.
attr
(
"y"
,
"80"
)
.
attr
(
"width"
,
"100"
)
.
attr
(
"height"
,
"50"
)
.
attr
(
"class"
,
"rect"
)
;
return
svg
.
node
(
)
;
}
Insert cell
Insert cell
html
`
<style type="text/css">
#svg {
background-color: black;
}
.rect {
fill: white;
}
</style>
`
Insert cell
Insert cell
d3
=
require
(
"d3@6"
)
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.
Try it for free
Learn more
Fork
View
Export
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
d3
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML