Recently I’ve been digging into Julia for
technical and statistical computing. It’s still in its early stages
and things break frequently, but I find it a lot more amenable to my
style of thinking than the more established technical languages like
Matlab/Octave or R.
Continue reading
As I’ve ironed out the basic issues in
hbg-crime.org’s data collection process, I’ve
been starting to think about adding some slightly more sophisticated
analytics. One feature I had in mind from the beginning is classifying
crime reports based on their neighborhood, so I dug around and found
this decent approximation of Harrisburg neighborhood
boundaries.
Google allows you to export these maps as KML files, so I just
extracted the coordinates into two-dimensional vectors directly in
source:
Continue reading
For whatever unknowable reason, the Harrisburg PD publishes its crime
blotter in PDF format. It’s simple monospaced text with no images or
extra formatting, but it comes as a PDF that has to be stripped in
order to parse its contents. Here’s how I did that with Clojure and
PDFBox.
Continue reading
I’ve been having a reasonably productive time getting up to speed
with ClojureScript for my Harrisburg city crime
tracker. One difficult bit of trial-and-error I
came across is successfully compiling the Google Maps API into my app
with advanced optimizations set. The Google Closure compiler munges
identifiers
so you need an “externs” file so it knows which names correlate to
what from your CLJS code.
Continue reading