Thank you Vladimir Agafonkin!

I’ve been using LeafletJS to create online maps since 2013:

None of this would have been possible without Vladimir Agafonkin. LeafletJS enables easy creation of online maps. An ecosystem of plugins enables use of different background maps and images, lines and shapes, different markers, overlays, clusters, heat maps, data visualisation, events and so much more! Much of this free and open-source. There is also a free WordPress plug-in, but you’ll need a paid WordPress instance to use plugins. Hence this map is elsewhere:

Click the image to get to the actual map!

Anyway, thank you Vladimir. I hope you and yours are safe, and that Mr Putin just stops!

Advertisement

Creative industries in south-east Scotland – mapped

Recently, I created online maps of creative companies in Scottish Borders, the Lothians, Edinburgh and Fife (collectively ‘south-east Scotland’). This was commissioned by the Creative Informatics programme, which aims ‘to explore how data can be used to drive ground-breaking new products, businesses and experiences’, among other good things.

Without further ado, here are the maps:

Below I rant about the problems encountered in this project – they are almost all about the data.

Continue reading

PhD studentship available at Edinburgh Napier University

(adapted from an email from Professor Hazel Hall)

Edinburgh Napier University is keen to receive applications from Computer Science or Software Engineering Bachelors or Masters graduates (or final year/Masters students due to graduate) with (or on target for) a first class or 2.1 degree, and who have some experience of studying Artificial Intelligence, Natural Language Processing, or Machine Learning (e.g. as part of a module, or in a project). Continue reading

Global Challenges Research Fund: sector meeting 29 October 2019 #GCRF

The Global Challenges Research Fund (GCRF) ‘is a £1.5 billion fund announced by the UK Government in late 2015 to support cutting-edge research that addresses the challenges faced by developing countries’. Its delivery partners include the Scottish Funding Council (SFC). Earlier this year, I was commissioned by the SFC to produce a web-map of the GCRF projects it funds.

I was invited to present about the map at the SFC’s GCRF sector meeting at the sector meeting on 29 October.

Hence a major part of this post is to record what Isaid about the map. The other major part is slightly edited versions of my live-tweets from the meeting. The rest of the post is Bruce-thoughts tweeted at the time, in (round brackets), and Bruce-thoughts that occurred while writing this post, in [square brackets].

My work was very well received, so I am very happy to have boosted my reputation (and that of Edinburgh Napier University), with representatives of the other Scottish universities, and with a significant research-funder.

All photos and information reported below are © the presenters and their relevant colleagues. Click the images to see the full-size versions. Continue reading

Edinburgh Apps competition: 6 February

(adapted from an email from OK Scotland)

The annual EdinburghApps event returns on  6 February 2016.

The ethos behind EdinburghApps is to run a unique civic challenge event for the City of Edinburgh that allows teams and individuals the opportunity to work with the City of Edinburgh Council and partners to provide fresh ideas and solutions to help improve the lives of those living, working and visiting the city.

EdinburghApps also supports the Council’s Open Data strategy, and opens up new data as part of the event to support participants. Continue reading

Wise words and mega maps

Leah Lockhart, social media advisor and all-round good egg, has been blogging about fears and barriers in public services on LinkedIn. Here are her thoughts on fears people have about being abused online, fears around negotiating online identity, fears digital champions have about inertia generally but especially in hierarchical leadership and finally about fears around BYOD.

Thanks also to ‘Lelil’ for drawing me to Leah’s tale of how to use topical hashtags to draw extra traffic to community council Tweets.

Well worth a read for any CC member (or any other elected member or public servant) involved in digital engagement with their citizens, in my opinion.

Continue reading

2014_04_06

So what’s happened over the last month?

Community council location finder project

The final community council location finder code has been submitted to the client. There were a few days delay waiting for up-to-date data to arrive at the client.

I look forward to the site going live. Meanwhile, here are screenshots of the final version:

Current project

I’m doing the literature review for the resurvey of Community Council online presences. This will update the summer 2012 report. To create connections with European research, it’s likely that I will examine how open-ness and transparency are supported by these presences.

Presentations

Peter Cruickshank and I have

I took part in the commission’s panel discussion around digital democracy. Here is the original submission. (Thanks as ever to Peter for making my prose legible.) Here is video of the discussion.

Yesterday, I was a note-taker at From Centre to Community – reclaiming local democracy in Scotland. My personal aim was to learn from others at this event, and this was more than fulfilled. I also met ‘Paddy’ Bort, co-author of The Silent Crisis, and Adam Stewart, secretary to the commission, among many others. Most people I spoke to were very well informed and had a lot to contribute. Others came simply to learn.

Many good points were raised – not just pie-in-the-sky schemes. I’m not optimistic that local democracy will be perfected in my lifetime. In fact, I am certain that nothing in this world can ever be perfect. But I am very optimistic that we can start to improve matters, right here, right now.

 

2014_03_11: it’s progress Jim, but not as we know it

So I spent most of yesterday trying to find what causes my work to crash Safari under iOS7: turns out it’s the gizmo that clusters the CC markers. Not going to cure that in a hurry!

Then I tried for several hours to add the info features from leaflet’s chloropleth/geoJSON example to my script. I got the LAs to highlight on mouseover, but not to de-highlight on mouseout. Nor could I get the data control to pick out data from the LA geoJSON file.

So I reasoned ‘if I can’t add their stuff to mine, can I add my stuff to theirs?’ That is, could I swap in my LA and CC data sets and use leaflet’s code to colour them and pick out data to be displayed in their external control? This seemed to go OK until I added in the geocoder (the bit for entering an address to zoom to that area of the map. This code failed, so everything that should have been processed after it wasn’t even reached.

I went back to trying to add leaflet’s functions to my otherwise functional code. Still no joy.

I refactored my code so it was in a more logical order:

  1. preparatory functions,
  2. drawing basic map
  3. adding scale, geocoder, reset and help controls to map
  4. adding LA data layer
  5. adding CC data layer
  6. adding layers on/off control

and made the reset control call a URL from a simple configuration file, so that when the client actually puts this work online, they only need to update the configuration file, not hack around in the reset script.

I still couldn’t get the mouseout bit to work. I knew this code was being called: if I replaced it with document.write(“rude word”); then rude words were written.

So this evening I revisited leaflet’s example, determined to get it to work. This example has all the functionality built into a script in the html file, not a separate ‘external’ script. Not really the way I want but I’m running out of time…

I realised that the geocoder was being called but just failing somewhere. I’m not sure how I worked it out but the fail point was that geocoder calls a function in my main external script to limit its searches to Scotland – the same bounds as are applied to my map. (Without this search-area limiting, searching for EH10 postcodes shows Walthamstow.) But this script is never invoked, so the function isn’t callable. So instead of calling that function, I’ve copied it into the geocoder. Now that works! And so do all the other bits. I can make the reset script call the configuration file, so long as they are in the right order in the html header (i.e. configuration before the reset function that depends on it – so perhaps the issue was that the geocoder was calling the main script before it was available.

There was another wrinkle adding in the CC marker code. Something doesn’t like a variable called location. Changing that to ccLocation worked.

So here is the whole lot working – but with the javascript embedded in the HTML.

My task for tomorrow is to get the javascript into a separate file, so that this works, cos right now it doesn’t. Then write some documentation, then write a talk for the OKFN meet-up tomorrow.

2014_03_10

Added reset button

It’s another hack down of the OSMGeocoder control, mostly because I don’t have time to understand how to create a control from scratch. The main fault with it is that it relies on

inner.innerHTML = “<a href=\”http://localhost:8888/realISV22\”><img src = \”css/images/reset.png\”></a>”;

The bold bit will need to be replaced with the real URL for wherever the site will be used.