Sunday 8 March 2015

A different growth model

This is slightly technical, but oh well.

The exponential and linear growth models for Neil aren't going to be valid for long, so I've constructed a logarithmic model which should last far longer. The trick to constructing such models is that they should be relatively easy to parametrise. Most data tools like Excel or Google Sheets (which I'm using for Neil's data) have linear parametrisation functions so it's great if the model in question can be transformed into a linear form for this purpose. So I've constructed the logarithmic model with this in mind.

It is

where w is Neil's weight, delta t is the time since his lowest weight in days, b is a time scalar, e is Euler's constant, i.e. 2.718..., and epsilon is an error term, which I'd like to be as close to zero as possible. The parametrisation needs to set b and epsilon, as all other variables are already known. It would have been nice to have a third multiplicative parameter outside of the logarithm but that makes the model non-linearisable. So this will have to do.

Taking antilogs yields

which is nice because when you set
,


and

you get the familiar linear form

where x is delta t.

So, using Neil's growth data, it turns out that epsilon is -0.17 for now, which looks small, but is it? Considering the other terms in the logarithm, epsilon contributes just over 6% of the magnitude at delta t of zero and its relative contribution therefore just decreases thereafter. So, yes, the error is small* and the model fits well at this stage, with the largest apparent error at the time when Neil was at his lightest (i.e. two days after birth). Sure enough, this can be seen from the graph:

The thin green line is the logarithmic model

Now we need more data to see how long the model holds! This morning, while nobody else was listening, Neil and I discussed what we'd do once the model doesn't fit well any more. We thought of a nice way of segmenting his growth into more than one sub-model and elegantly joining the sub-models together using a very cool transition function, which I've been itching to use for some time now, but haven't had the chance. More on that in a later post though.

*Anything lower than 10% is pretty much 0 as far as I'm concerned!

1 comment:

  1. Arme Neil ek het nie geweet hy is so tegnies voorspelbaar nie. Baie interessant

    ReplyDelete

Hi! Select the "Comment as Anonymous" option in the comment form for the least hassle.