Platform
Resources
Pricing
Sign in
Get started
Kurtis Pivert
Interested in communicating data-driven insights. Director of Data Science at @ASNDataAnalytics.
Workspace
Fork
Public
By
Kurtis Pivert
Edited
May 18, 2023
Fork of
Learn Observable Workshop
1
Insert cell
Insert cell
import
{
pizzariaDB
}
from
"@observablehq/pizza-paradise-data"
Insert cell
Select a data source…
Filter
Columns
Sort
Slice
Save
Type Table, then Shift-Enter. Ctrl-space for more options.
Insert cell
Plot
.
plot
(
{
marks
:
[
Plot
.
density
(
cars
,
{
x
:
"power (hp)"
,
y
:
"economy (mpg)"
}
)
]
}
)
Insert cell
Insert cell
Insert cell
Insert cell
b
=
a
*
10
Insert cell
Insert cell
test_iris
=
FileAttachment
(
"test_iris.csv"
)
.
csv
(
)
Insert cell
test_iris
Filter
Columns
Sort
Slice
Save
Type Table, then Shift-Enter. Ctrl-space for more options.
Insert cell
viewof
file
=
Inputs
.
file
(
{
label
:
"Data"
}
)
Insert cell
mta
=
d3
.
json
(
"https://data.ny.gov/resource/vxuj-8kew.json"
)
Insert cell
mta
Filter
Columns
3
Sort
1
Slice
Save
Type Table, then Shift-Enter. Ctrl-space for more options.
Insert cell
subways
Clear All
Swap X/Y
Customize
X
Date
Y
Subways
Color
Buses
Size
—
Facet X
—
Facet Y
—
Mark
line
Type Chart, then Shift-Enter. Ctrl-space for more options.
Insert cell
Plot
.
auto
(
subways
,
{
x
:
"Buses"
,
y
:
"Subways"
,
color
:
"Buses"
,
size
:
"Subways"
}
)
.
plot
(
{
marginLeft
:
100
,
color
:
{
legend
:
true
}
}
)
Insert cell
Insert cell
viewof
color
=
Inputs
.
color
(
{
label
:
"Viz Color"
,
value
:
"#4682b4"
}
)
Insert cell
Plot
.
plot
(
{
grid
:
true
,
marks
:
[
Plot
.
ruleY
(
[
0
]
)
,
Plot
.
lineY
(
subways
,
Plot
.
windowY
(
{
x
:
"Date"
,
y
:
"Subways"
,
k
:
range
,
reduce
:
"mean"
}
)
)
,
Plot
.
lineY
(
subways
,
{
x
:
"Date"
,
y
:
"Subways"
,
stroke
:
color
}
)
]
,
marginLeft
:
100
,
marginRight
:
50
}
)
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
Compare fork
Fork
View
Export
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
File attachments
test_iris.csv
CSV
Databases
Filter
Column
Operator
Columns
Sort
Column
Direction
Descending
Ascending
Slice
From
Start
To
End
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
a
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
c
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
b
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
b1
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
test_iris
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
Cells
test_iris
File attachments
test_iris.csv
CSV
Databases
Filter
Column
Operator
Columns
Sort
Column
Direction
Descending
Ascending
Slice
From
Start
To
End
file
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
mta
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
subways
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
Cells
mta
File attachments
test_iris.csv
CSV
Databases
Filter
Column
Operator
Columns
Sort
date
Ascending
Descending
Ascending
Column
Direction
Descending
Ascending
Slice
From
Start
To
End
Add comment
Select
Duplicate
Copy link
Embed
Delete
Cells
subways
File attachments
test_iris.csv
CSV
Customize
Clear
Title
Subtitle
Caption
Height
Width
Auto
Full
Margin
Top
Right
Bottom
Left
Inset
Legend
Auto
None
X label
X scale
Auto
Scale
Auto
linear
log
sqrt
symlog
point
band
X options
Grid
Reverse
Y label
Y scale
Auto
Scale
Auto
linear
log
sqrt
symlog
point
band
Y options
Grid
Reverse
Color scheme
Auto
Color scheme
Auto
Default color schemes
Sequential
Diverging
Cyclical
Categorical
Sequential color schemes
Blues
Greens
Greys
Oranges
Purples
Reds
Turbo
Viridis
Inferno
Magma
Plasma
Cividis
Warm
Cool
BuGn
BuPu
GnBu
OrRd
PuBuGn
PuBu
PuRd
RdPu
YlGnBu
YlGn
YlOrBr
YlOrRd
Diverging color schemes
BrBG
PRGn
PiYG
PuOr
RdBu
RdGy
RdYlBu
RdYlGn
Spectral
Cyclical color schemes
Sinebow
Turbo
Categorical color schemes
Category10
Accent
Dark2
Paired
Pastel1
Pastel2
Set1
Set2
Set3
Tableau10
Color scale
Auto
Scale
Auto
linear
log
sqrt
symlog
categorical
ordinal
Color options
Reverse
Reducer
—
Auto
—
count
distinct
sum
min
max
mean
median
mode
Field
—
Reducer
—
Auto
—
count
distinct
sum
min
max
mean
median
mode
Field
—
Reducer
—
Auto
—
count
distinct
sum
min
max
mean
median
mode
Field
—
Reducer
—
Auto
—
count
distinct
sum
min
max
mean
median
mode
Field
—
Field
—
Field
—
Mark
Auto
bar
dot
line
area
rule
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
range
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
color
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML