Skip to content

Instantly share code, notes, and snippets.

View transientlunatic's full-sized avatar

Daniel Williams transientlunatic

View GitHub Profile
@transientlunatic
transientlunatic / README.md
Last active August 24, 2024 11:49
EMF 2024 Results

These are anonymised results for the Edinburgh Marathon's 2024 running.

@transientlunatic
transientlunatic / README.md
Last active June 12, 2024 15:33
EVE Spectra

Notebooks for EVE Spectra

@transientlunatic
transientlunatic / README.md
Last active April 22, 2022 07:14
Relative Hills of Glasgow

This gist contains a list of all hills in Glasgow which have a height of at least 30m and a topological prominence of 10m or more.

The heights were deteremined by analysing Scottish Government remote sensing data available here: https://remotesensingdata.gov.scot/data

@transientlunatic
transientlunatic / GPX.ipynb
Last active December 15, 2021 12:42
Mountain images
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@transientlunatic
transientlunatic / README.md
Last active April 30, 2020 09:26
Data from the "Wheel of Time" series.

Wheel of Time Data

This repository contains sporadic bits of data derived from the "Wheel of Time" novels by Robert Jordan, and I intend, at some point in the far distant future to use these to make some entertaining visualisation of what happens in the books. For now, however, it's just data.

@transientlunatic
transientlunatic / Covid-19.ipynb
Last active January 26, 2021 14:40
Covid-19 in Scotland
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@transientlunatic
transientlunatic / altair.py
Last active May 26, 2020 15:44
Some useful plotting styles
import altair
def pastle():
# Typography
font = "Lato"
# At Urban it's the same font for all text but it's good to keep them separate in case you want to change one later.
labelFont = "Source Code Pro"
sourceFont = "Lato" # Axes
axisColor = "#000000"
gridColor = "#4298bd" # Colors
main_palette = ['#8dd3c7', '#ffffb3', '#bebada',
@transientlunatic
transientlunatic / Sunset plots.ipynb
Last active December 14, 2021 18:14
Calculate the earliest sunset and the latest sunrise in winter.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@transientlunatic
transientlunatic / mcmc.tex
Created March 17, 2019 09:54
Markov chain illustration in LaTeX
\newcommand\gauss[2]{1/(#2*sqrt(2*pi))*exp(-((x-#1)^2)/(2*#2^2))}
\newcommand\complicated{ 0.5*( 1/(.2*sqrt(2*pi))*exp(-((x-1)^2)/(.2*2^2))) + 0.5*(1/(.5*sqrt(2*pi))*exp(-((x-5)^2)/(.5*2^2)) ) }
% Gauss function, parameters mu and sigma
\begin{tikzpicture}
\foreach \x in {1,2,...,4}{
\begin{scope}[xshift=1cm, yshift=1.5*\x cm]
@transientlunatic
transientlunatic / hexmap.tex
Last active April 29, 2021 20:56
Hexagons for map-making in the Traveller RPG
%
% x=3*(minimum size)/2
% x=\sqrt{3/4}*(minimum size)/2
%
\usetikzlibrary{shapes.geometric}
\usetikzlibrary{calc}
\def\hexdia{1cm}