Taxonomic diagrams

I’ve been trying to work out a way to automatically generate taxonomic species diagrams from my species list. I’ve nearly achieved it, subject to one annoying problem. It’s close enough though, so I’ve put it live anyway. The diagrams can be reached by selecting ‘diagram’ from the ‘view mode’ option on the species list. Like the list itself, the diagram will regenerate when filters are applied from the left hand side of the page.

The problem that I haven’t yet solved is the unwanted vertical lines that don’t connect to anything. I know exactly why it happens, but I’m yet to figure out the logic to avoid it happening. I can see a couple of solutions that will work, but not without hitting the database for every single data item on the diagram, which is too much overhead. The problem stems from having to generate the diagram sequentially, but needing foresight of the data that is yet to be read, so that it’s possible to determine whether a particular data item is the last one within its parent’s group. If I can’t find a solution, it will stay as it is – it works, and it’s close enough. However, I’ll try to solve it – weirdly, I enjoy this stuff.

*update* The problem is now resolved 🙂

Previous Post

Species List filters

The species list has been further improved to accommodate the inclusion of kingdoms other than the previous singular 'animalia' kingdom. Previously there were two methods of filtering by country. The first was using a drop-down menu, which has now been removed as it duplicated functionality. Whatever filters and sorting rules ... Read more

Next Post

Trip report from the future

I didn't expect to be writing this trip report exactly two weeks before I'd even left the country, but here we are. Foreign Office advice and airlines pulling out of flying to my destination mean that my next trip isn't happening, and will have to wait for a future date. ... Read more

Skip to content