Published
Edited
Nov 24, 2021
Importers
Insert cell
Insert cell
Insert cell
Insert cell
**Scratch**

* Find datasets that cover neobank & "nonbank" deposit share growth (Chime, Varo, etc.) + credit unions (NCUA) -- CFPB? FFIEC? etc.


Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
geojson = locations.data.map(d => ({
type: "Feature",
geometry: {
type: "Point",
coordinates: [d.data.LONGITUDE, d.data.LATITUDE]
},
properties: d.data.NAME
}))
Insert cell
Insert cell
Insert cell
locations = d3.json(url2, d3.autoType)
Insert cell
locationData = locations.data.map(d => d.data)
Insert cell
locationTable = Inputs.table(locations.data.map(d => d.data), {columns: ["ID", "NAME", "ESTYMD", "ZIP", "CITY", "COUNTY", "LATITUDE", "LONGITUDE"]}, {sort: "ID", reverse: true})
Insert cell
geoLocation = {
const createGeoJSON = () => {
const data = [
{
lat: locationData.getElementById("LATITUDE").value,
lng: locationData.getElementById("LONGITUDE").value
}
];
data[0][locationData.getElementById("propertyname1").value] = document.getElementById("propertyvalue1").value;
data[0][locationData.getElementById("propertyname2").value] = document.getElementById("propertyvalue2").value;
const dataGeoJSON = locationData.parse(data, { Point: ["lat", "lng"] });
locationData.getElementById("output").value = JSON.stringify(dataGeoJSON, null, 4);
}
}
Insert cell
map = {
const container = html`<div style="height:650px;">`;
yield container;
const map = L.map(container).setView([45.2, -69.5], 7);
L.tileLayer("https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png", {
attribution: "&copy; <a href=https://www.openstreetmap.org/copyright>OpenStreetMap</a> contributors"
}).addTo(map);

L.svg().addTo(map)
const overlay = d3.select(map.getPanes().overlayPane)
const svg = overlay.select('svg')

const branches = svg.selectAll('circle')
.attr("class", "branch")
.data(geojson)
.join('circle')
.attr("id", "dots")
.attr("fill", "blue")
.attr("r", 5)
}

Insert cell
L = {
const L = await require("leaflet@1/dist/leaflet.js");
if (!L._style) {
const href = await require.resolve("leaflet@1/dist/leaflet.css");
document.head.appendChild(L._style = html`<link href=${href} rel=stylesheet>`);
}
return L;
}
Insert cell
Insert cell
Insert cell
bankTable = Inputs.table(banks.data.map(d => d.data))
Insert cell
simpleBankTable = Inputs.table(banks.data.map(d => d.data), {columns: ["ID", "NAME", "ZIP", "OFFICES", "DEPDOM"]}, {sort: "DEPDOM", reverse: true})
Insert cell
viewof filteredRows = Inputs.table(filteredBanks)
Insert cell
Insert cell
viewof deposits = Inputs.range([0,1500000], {value: 1200000, step: 100, label: "Minimum Deposits"})
Insert cell
chart = addTooltips(Plot.plot({
marks: [
Plot.barY(filteredBanks, {x: "ID", y: "DEP", title: "NAME", fill: colorScale})
],
width: 800
}))
Insert cell
Insert cell
Insert cell

One platform to build and deploy the best data apps

Experiment and prototype by building visualizations in live JavaScript notebooks. Collaborate with your team and decide which concepts to build out.
Use Observable Framework to build data apps locally. Use data loaders to build in any language or library, including Python, SQL, and R.
Seamlessly deploy to Observable. Test before you ship, use automatic deploy-on-commit, and ensure your projects are always up-to-date.
Learn more