Comments (8)
I wrote some code for address to lat-long lookups, which is stage 1 of this project. Next step is being able to map a lat-long to a district. My understanding is that our current JSON files are just shapefiles with no lat-long info in them. I pulled a handful of the district geoJSON files from Jeff's shapefile repo and mocked up some code that uses Shapely to get matches.
Speed is not great; it takes about 6 seconds to compute a full lookup for California. This does stand to reason, though, there are many megabytes of JSON to load, read, process, and match.
Regardless, I have a test example that will take UCLA's address and spit out a bunch of people who represented that point in space.
from webvoteview.
Jeff has a proof of concept for the back-end lookup that can do a full lookup in about 2.5 seconds. We're going to test some more about the impact on Mongo's RAM use and then eventually build a page.
from webvoteview.
I have not done any UI work or really any functionality yet [please, no feedback on "can it do this" or "shouldn't it look like this" or "does it prevent against this"], but there is a page that at least is a proof of concept for speed, which is plenty fast.
http://128.97.229.160/district
from webvoteview.
Nice!!! With the right UI this is going to be great.
Sent from my iPhone
On Oct 20, 2016, at 5:56 PM, Aaron Rudkin [email protected] wrote:
I have not done any UI work or really any functionality yet [please, no feedback on "can it do this" or "shouldn't it look like this" or "does it prevent against this"], but there is a page that at least is a proof of concept for speed, which is plenty fast.
http://128.97.229.160/district
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.
from webvoteview.
This seems to be somewhat broken at the moment. Some addresses don't work and I can't get any dropdowns of legislators to appear.
from webvoteview.
Luke; this was a DB issue that popped up over the holidays. Adam mostly fixed it, but missed something with the district shapefiles. It is fixed now -- I will get back to finishing the UI stuff.
from webvoteview.
I wired up NOMINATE here, but it doesn't quite work. See #106
from webvoteview.
I implemented Jeff's line suggestion and tooltips so this function is provisionally "done" and I can mark this as closed. Further discussion in #106 for implementation, I guess?
from webvoteview.
Related Issues (20)
- Congress page doesn't load HOT 1
- Parties at a glance should hide minor parties by default
- Fix party page for party 328 (independent) -- JS error [python3 only]
- Add congress codes to metadata
- Brush to select on Congress DW-NOMINATE plot shows NaN when selecting far-right
- Wikipedia key vote not an option on search facets
- Check or update service dates HOT 1
- Rewrite JS in modern-ish (ES6 or newer) Javascript
- Better link previews for rollcall votes
- Party bios should support HTML
- Trump vote on Gorsuch may be wrong
- Map download colors missing HOT 1
- Bulk vote download problem
- More friendly 500 error page
- Downloading zoomed map HOT 1
- Data downloads all 404 HOT 4
- Show member departures
- Add issue codes to csv files
- Scalia confirmation vote
- Load 97th Congress bill numbers
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from webvoteview.