Tracking — Behind the scenes

Matt Dalton
Finimize Engineering
4 min readDec 18, 2017

A few weeks ago we introduced tracking. This is our first attempt at bringing your financial plan closer to your daily life by allowing you to track progress towards your goal every month and optimize your investments accordingly.

One thing a financial advisor might tell you is that, whatever plan you make, it will be wrong. Markets fluctuate, pay rises might not happen, you might suddenly decide you no longer need that car - it’s all likely to change.

Once you accept this, it’s very clear that users need a way to track how they’re following their plan, so they can adapt it accordingly. Let’s walk through a simple example to see how we do this behind the scenes…

Every goal you wish to achieve in MyLife can be represented by a savings target (e.g. £2000 for a flashy new laptop 💻) and a deadline you want to achieve it by. This gives you a payment plan to follow each month. For example…

Say you now add a few more goals and you want to start saving towards each of them every month. You might have 3 goals, each with their own timelines, targets and planned monthly payments. You will also have a preferred priority in which you want to pay into these.

This is fine for now, but plans change! At that point, we need to be able to save your progress and adapt flexibly as this happens.

So one month later, you’re still caught up in a whirlwind of financial proactivity, so you slam down the £170 you planned for into your savings/investment account 💰.

When you record a payment, we calculate the monthly payments you need to cover the remaining target in the time left. Since this is basically the same as calculating a new plan, we call this ‘shifting the plan’. We save the progress made towards each goal in an ‘amountLastShifted’ variable.

A month later and…oh dear. December happened 🎅🏻. You only have £30 to put away this month because of your excessive spending on food, scalextric and fine wine.

Because your goals are ordered by priority, each goal takes what it can from this £30.

A month later…phew. Christmas really came through. A combination of your aunt’s generosity and a new year detox means you now have £400(!) to make amends. Let’s see how that looks for your goals…

But you also have 400–20–190–100 = £90 leftover. Where should this go…?

We built a greedy allocation algorithm to decide what to do in these situations. In practice this means that once you’re up to date with your plan, each goal then takes whatever it can from any additional money you throw in. In priority order, of course.

We only begin this greedy allocation process once each goal is up to date with the plan, otherwise lower goals wouldn’t be paid off until the goals above it were completed.

Now let’s say you come back 5 months later. According to your plan you should have completed all your goals!

Luckily, you have in fact been saving, and have £200.

As always, there are of course far more nuances and edge cases than we can go through in a reasonably worded blog post. But hopefully these examples illustrate some of the technical challenges we’re tackling in trying to improve the user experience.

If you want to help us build more cool stuff, check out our open positions: www.finimize.com/jobs

If you’ve seen something in MyLife that made you wonder how we built it, feel free to get in touch with a suggestion for our blog ✍️

--

--