Lee Hodg

Monthly Archives: September 2022

A/B Testing

A/B Tests and Experiment Size

Let’s say you’re running an A/B test. Maybe you want to test how many conversions you will get if you change the design of the Signup page or the wording. You split users landing on your site into 2 groups – the control group and the experimental group. Those in the control group see the […]

NLP Pipelines with NLTK

Often with Natural Language Processing (NLP) applications a pipeline is useful to take the raw text and process it and extract relevant features before inputting it into a machine learning (ML) algorithm. Normalization From the standpoint of an ML algorithm, it may not make much sense to differentiate between different cases of a word – […]

Jupyter x AWS

Setting up Jupyterhub on AWS

This guide will be about setting up the fiddly bits when deploying a Jupyter Hub to an AWS instance. It won’t go into explicit detail about absolutely every step as the docs already do a great job of that. The purpose of this post is to discuss the things I found tricky after the install […]

Backprop: coding it up

In a previous post, I walked through the maths of back-propagation (“backprop”). Here I will go through the implementation in Python (heavily based on Andrew Ng’s course). I’m going to use the alternative form equations (in the last blog post I denoted those with a tilde, but now I will drop that tilde). This means […]

Coin Flip

Deciding if a coin is fair

We can have a statistical model for single flip of the coin: $(\{0, 1\}, \{\sim\text{Ber}(p)\}_{p \in (0, 1)})$ (means the result is either 0 (tails) or 1 (heads) and the distribution is just a Bernoulli with prob $p$ of $1$ and $(1-p)$ of $0$) Then the null and alternative hypotheses are * $H_0$: coin is […]