Platform
Resources
Pricing
Sign in
Get started
Wille Marcel
Software Engineer at Development Seed
Workspace
Fork
Public
By
Wille Marcel
Edited
Aug 16, 2023
1
Insert cell
Insert cell
df74a7b7-0b70-478b-93ae-d8ec4e0ecb97.csv
Filter
1
Columns
Sort
Slice
Save
Type Table, then Shift-Enter. Ctrl-space for more options.
Insert cell
dataJson
=
FileAttachment
(
"df74a7b7-0b70-478b-93ae-d8ec4e0ecb97.csv"
)
.
csv
(
)
Insert cell
(
{
type
:
"FeatureCollection"
,
features
:
features
}
)
Insert cell
function
getValue
(
n
,
startPoint
)
{
return
n
.
split
(
startPoint
)
[
1
]
?.
split
(
", "
)
[
0
]
;
}
Insert cell
function
getCategory
(
c
)
{
return
c
.
split
(
"{main="
)
[
1
]
.
split
(
", "
)
[
0
]
;
}
Insert cell
function
clean
(
i
)
{
return
i
.
replace
(
"["
,
""
)
.
replace
(
"]"
,
""
)
;
}
Insert cell
function
getNumber
(
n
,
startPoint
)
{
return
n
.
split
(
startPoint
)
[
1
]
?.
split
(
", "
)
[
1
]
?.
replace
(
"}]"
,
""
)
;
}
Insert cell
parser
=
require
(
"https://bundle.run/wellknown@0.5.0"
)
Insert cell
Insert cell
geojsonFile
=
makeGeojson
(
dataJson
)
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
df74a7b70b70478b93aeD8ec4e0ecb97
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
File attachments
df74a7b7-0b70-478b-93ae-d8ec4e0ecb97.csv
CSV
Databases
Filter
addresses
Operator
Column
Operator
Columns
Sort
Column
Direction
Descending
Ascending
Slice
From
Start
To
End
dataJson
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
getValue
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
getCategory
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
clean
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
getNumber
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
parser
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
makeGeojson
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
geojsonFile
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML