60 second stats – Hamish Thorburn /stor-i-student-sites/hamish-thorburn PhD Student, STOR-i Centre for Doctoral Training Mon, 08 Nov 2021 10:30:15 +0000 en-US hourly 1 https://wordpress.org/?v=6.9.4 60 second stats – Monte Carlo Simulation /stor-i-student-sites/hamish-thorburn/2020/04/19/60-second-stats-monte-carlo-simulation/?utm_source=rss&utm_medium=rss&utm_campaign=60-second-stats-monte-carlo-simulation Sun, 19 Apr 2020 14:12:47 +0000 http://www.lancaster.ac.uk/stor-i-student-sites/hamish-thorburn/?p=219 So, the plan for this post was to look at . However, in doing that I realised that:

  1. In order to understand the paper and why it’s important, the reader (i.e. you) need to first understand what a Monte Carlo approximation is… which would be fine, except that;
  2. The only real way I could fit that into the post would be to embed a YouTube video describing it into the start of the post… which would be fine, except that;
  3. Pretty much all the YouTube videos on this are really boring.

Therefore, I thought the best thing to do would be go back to basics, and try and give a quick explanation of Monte Carlo Estimation myself. And what better way to give a quick overview is there than another edition of 60 second stats?

So get out the stopwatch, and get ready. The 60 seconds begins…NOW!

What is Monte Carlo Estimation?

Monte Carlo Estimation is a technique used to estimate quantities. It is based around simulating a bunch of random numbers, and then using these to make estimates.

Why is it called “Monte Carlo”?

It is named after the Monte Carlo Casino, in Monaco, which was frequented by the uncle of Stanislaw Ulam, one the methods founders. It is also a reference to the inherent randomness of the method (as all casino games are based on chance).

Some beautiful architecture that just screams “computational statistics”.

Ok. So how does it work?

The overall idea is very simple. Say you have a random variable X, and you want to estimate some value related to X (e.g. it’s average). You can then simply simulate a large number of realisations (i.e. copies) of X, and take the average of these. Then (because of the ) we know that the average of our copies will be a “good” estimation of X.

Wait, what do you mean by “good”?

What we mean by “good” is that as you take more and more realisations of X to average, the average will get closer and closer to the true value, as shown in the gif below.

The gif clearly shows that the more copies, the closer to the true value we get.

Alright. So how do I do it myself?

It’s easy! All you need is:

  1. A method/program/algorithm to simulate copies of your random variable
  2. Enough computational power/storage to simulate and store many copies of this variable (the more the better)

…and that’s time! Thanks for participating in another edition of 60 second stats. If you want to know more, there are many further aspects to this, such as known results about the , or what to do if you .

]]>
60 second stats – Agent-Based Simulation /stor-i-student-sites/hamish-thorburn/2020/02/25/60-second-stats-agent-based-simulation/?utm_source=rss&utm_medium=rss&utm_campaign=60-second-stats-agent-based-simulation Tue, 25 Feb 2020 20:34:30 +0000 http://www.lancaster.ac.uk/stor-i-student-sites/hamish-thorburn/?p=192 I thought I’d try something different today, and instead of the regular post, I thought I’d try and do a bite-sized summary of a topic. To that end, please enjoy the first installment of 60 second stats! I can’t install a clock in the post, but if you’re really keen, time yourself to see if I’ve done a good job. Today’s topic will be the area of Agent-Based Simulation.

Are you ready?

….GO!

What is Agent-Based Simulation?

Agent-based simulation is any computer simulation in which “agents” interact with each other.

No, not like that.

The agents can be simulated cells in a biological system, or animals in nature, or even people. You then set your simulation running to see how the agents interact.

How do I make an agent-based simulation?

Basically, an agent-based simulation needs 3 elements:

  1. Agents
  2. Relationships/interactions between the agents
  3. An environment the agents exist in

These will often be determined by either the structure of the simulation, or by parameters inputted by the user at the start of the simulation.

Are there any examples of this?

Yes! To pick just a couple of the countless examples, agent based simulation has been used to model:

  • Predator-Prey relationships between animals ()

And many others.

What do I use an agent-based simulation for?

Often it’s used to either:

  1. Study how the agents interact under certain conditions, because studying these conditions in real-life is difficult/impossible
  2. Predict how real-life agents would act in new situations/environments they haven’t experienced before

That seems simple enough. Are there any problems with it?

The main difficulty is calibration. That is, selecting the right parameters so that the simulation is behaving similarly to the real-life system it is modelling. Otherwise, you can’t trust any of the results you obtain from it.

Which can be heartbreaking when you realise this

How do you calibrate it?

The most common way seems to be trial-and-error – just keep testing new parameters until the output looks realistic. However, there has been a bigger post to start using heuristics to try and automatically calibrate agent-based simulations

That sounds familiar…

It should! It was the topic of

60 seconds is nearly up. Where do I look if I want to know more about this?

give a really good overview of general agent-based simulation. For some examples for the automatic calibration, see or .

Aaaand, that’s time. Hope you enjoyed that! If not, well, you only wasted one minute.

]]>