Which models drive decision-making and policy?

Lawrence Fishburne and Bryan Cranston in , a film describing the outbreak of a virus MEV-1. Image source: .

When COVID-19 swept the world in early 2020, researchers swarmed in with their modelling expertise to forecast epidemic spread and derive optimum interventions. Here’s a high-level view of the whole party.

The majority of mathematical models are derived from the SIR and SEIR compartment models. The primary use cases are population-level forecasting (e.g. predict timing of epidemic peak and hospitalisation numbers) and informing interventions strategies (e.g. lockdowns, quarantine, social distancing and wearing masks).

Define your own rules or let the data do the talking?

Jessica Chastain in . Image source: .

Let’s compare and contrast differential equations (DE) to data-driven approaches like (ML).

In a nutshell — albeit with caveats — they can be thought of different approaches to modelling various phenomena. Do you make the rules? Or should you let your juicy data learn the rules for you?

Both types of models absolutely drive the world around us. Let’s dig in.

Edit: I have written a sequel article .

Example DE models

Navier-Stokes (meteorology)

The model behind . It is a model — meaning predictions can be wildly off when using just slightly incorrect inputs. That’s why weather predictions are often…

A visual explanation + connections with probability

Image by Andy Kelly on .

This article is Part I of an series on deep-diving how machine learning algorithms are evaluated.

Here, we’ll visually review the most popular supervised learning metrics for

  • Classification — Accuracy, Precision, Recall, Fᵦ & AUC; and
  • Regression — MAE, MSE and R².

In short, the more advanced classification metrics allow you to calibrate the importance of Type I and II errors for your use case, while dealing with imbalanced datasets. We’ll also visually explore some connections between classification metrics and probability.

In and article, I apply these classification and regression metrics to real-world ML problems in Jupyter using…

The Secret Sauce Behind Financial Independence

Image source:

Albert Einstein is reputed to have said:

“Compound interest is the eighth wonder of the world. He who understands it, earns it — he who doesn’t, pays it.”

Understanding compound interest can transform your life, whether you’re investing for financial independence or scaling your startup business.

1. Compound Interest = Exponential Growth

Many people mistake compound interest for simple interest, which grows your assets linearly. Compounding assets grow exponentially*, which mathematically skyrockets their value. This effect is dramatically enhanced by the interest rate (i.e. exponent) and time in the market.

Consider putting $100 into a variety of asset types in 2010. Even though ’s annualised return…

Regression model trained on 1,883 homes

Image source: Barrister & Solicitor.

Property valuation is an imprecise science. Individual appraisers and valuers bring their own experience, metrics and skills to a job. Consistency is difficult, with UK and Australian-based studies suggesting valuations between two professionals can differ . Crikey!

Perhaps a well-trained machine could perform this task in place of a human, with greater consistency and accuracy.

Let’s prototype this idea and train some ML models using data about a house’s features, costs and neighbourhood profile to predict its value. Our target variable — property price — is numerical, hence the ML task is regression. …

Annualised return of 230% over 10 years. Get ready for a stellar 2021

Image source: .

Ten years ago, if you put aside $4 for that cup of into Bitcoin, you’d be sitting on a whopping today. Insane right?

That’s an annualised return of 234%. Compare that with:

Data suggests Democrats, but not because of Democratic leadership

Many are concerned about stock market performance surrounding the election. I am. Let’s take a data-driven deep dive (DDDD) into the situation.

Which party gives higher return to investors?

Short answer: Democrats, but not because of Democratic leadership.

Data shows that stock market returns are on average higher under a Democratic presidency. See & .

Classification model trained on 14,249 employees

Image source: Shutterstock.

It’s well-known in HR that recruiting new employees is substantially more expensive than retaining existing talent. Employees who depart take with them valuable experience and knowledge from your organisation. According to , the cost of an entry-level position turning over is estimated at 50% of that employee’s salary. For mid-level employees, it’s estimated at 125% of salary, and for senior executives, a whopping 200% of salary.

We’ll train some machine learning models in a using data about an employee’s position, happiness, performance, workload and tenure to predict whether they’re going to stay or leave.

Our target variable’s categorical…

Battle of the temporal pincers

Warning: This article contains massive spoilers.

Nolan directs John David Washington at the Oslo Freeport scene

One big loop

The whole film is a big loop, starting on ‘the 14th’ at the Kiev Opera House and ending on that same day at the Soviet closed-city of Stalask-12 and coast of Vietnam. The story tracks four characters — Protagonist, Neil, Kat and Sator — traversing a month forward in time, then a month inverted.

Col Jung

I write about data science, modelling and investing. I shoot short films on the weekends. Always learning.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store