Chris Worfolk's Blog


Stanford Introduction to Food & Health

May 5th, 2020 | Life

I’m officially a Stanford University graduate. I even have a certificate saying so. Sort of. It says “this is not the same as being a real student on campus!” at the bottom, but otherwise is pretty much says that.

I started the Introduction to Food & Health course last year. It was interesting, but not very science-heavy, hence I moved onto other qualifications such as the ones from Wageningen. For people looking to eat healthier and more interesting in improving their diet than understanding metabolic processes, this is a great course.

Stripe Payments in PHP

May 4th, 2020 | News

I’m pleased to announce my new course, Stripe Payments in PHP. It’s a 90-minute course that covers Stripe Checkout, API, Elements and Stripe.js: all the options you may want to use for integrating Stripe Payments into your website.

There are a couple of Stripe courses out there already. But a lot of them haven’t been updated for years and that is a problem because the EU is currently bringing in new some payment regulations across Europe called “Secure Customer Authentication”. This is a two-factor payment authorisation system in which your bank will text you a code (which is why your bank or credit card provider may have been nagging you to update your mobile number).

This course is fully up-to-date with Stripe’s new SCA-compliant APIs, as well as covering digital wallets such as Apple Pay and Google Pay.

Here’s the trailer:

Ironman VR4

May 3rd, 2020 | Sport

As I mentioned last week, I accidentally did a Half Ironman.

Easy mistake to make. Ironman Virtual Club’s original schedule had it rotating around middle, standard, sprint. I didn’t double-check the distance when I signed up for VR4, so went out to do my 5km run and 90km bike before collapsing on the sofa to watch the pro race. I then saw they were only cycling 40km.

By this point, I was too invested to drop my run down to a 10km, so I did the full 21.1. Alas, now Ironman VR5 has been upgraded to a middle distance race, and I can’t be bothered to do it all again this weekend.

May races

May 1st, 2020 | Sport

Tomorrow would have been Tour de Yorkshire. Instead, we’ve got an email confirming at World Triathlon Leeds has been upgraded from postponed to cancel. But not all is lost.

Everymayday 10k

As a fundraiser for the WHO COVID-19 Solidarity Relief Fund, we’re running 10km every day throughout May. That adds up to 310km in total, which is 7.3 marathons. I don’t feel super-prepared as it’s a higher weekly mileage than I usually do. But might be doable with plenty of easy runs and some run-walks, or just plain walks.

Find out more on the JustGiving page.

The Great Virtual Race Across Tennessee

From the mind of Gary Cantrell, creator of the Barkley Marathons, comes this virtual race. 1,021 kilometres from one corner of Tennessee to the other. Still, you have four months to complete it, which means you need to average 8.3km per day.

My original target was to do half of the distance. I think 500km is still a good crack at it. But, if I get through the #everymayday challenge, who knows. The important thing is that you get the t-shirt just for starting.

You still have time to sign up if you fancy the challenge.

Garmin activities not uploading

April 29th, 2020 | Tech

If you watch is syncing with Garmin Connect or Garmin Express, but not appearing in Garmin Connect, it could be that the activity has corrupted.

You can fix this by plugging your Garmin watch into your computer, browsing to Device/Garmin/ACTIVITY and finally finding the .FIT file. Try uploading this to Garmin Connect manually. If it says unsupported file type, you know you have a corrupt file.

Take it to Fit File Tools and run it through their fit file fixer. Download the result and try re-uploading it to Garmin Connect. Hopefully, it should be accepted this time.

Endure: Mind, Body and the Curiously Elastic Limits of Human Performance

April 28th, 2020 | Books

Endure: Mind, Body and the Curiously Elastic Limits of Human Performance is a book by Alex Hutchinson.

It’s an interesting book for understanding the limits of human performance from both a physical and psychological point of view. Not that all questions are resolved. But there is plenty of discussion.

Below, I have picked out a few points.

Typically, you don’t run yourself to exhaustion. Your brain stops you before you reach that point. And that starts from the minute you start exercising. For example, cyclists set off slower from the start on a hot day.

But when you get in sight of the finish, you know the danger is over and you can sprint. Hence we can be hurting so much until the final straight, at which point we find that last bit of energy to push across the line.

How does this work? Is there some kind of internal regulation in the brain that we are not consciously aware of? Or is there another explanation? For example, could we be tapping into anaerobic energy?

It seems likely that the brain does have some control. For example, everyone finishes a marathon in just under 3, 4, 5 hours. Only the brain can respond to these abstract concepts. So why do so many more people finish a marathon in 3:59 than 3:47?

Similarly, how is it that the limit that climbing a mountain without oxygen turns out to be almost exactly the high of Everest? If Everest was a little smaller, or a little larger, would it turn out that the limits of climbing without oxygen were different also? It seems likely given that it was thought to be impossible until Reinhold Messner and Peter Habeler did it. Then they changed the sums to show it was just possible.

Finally, a note on hydration. We often hear the idea that if you wait until you are thirsty, it is too late. But voluntary dehydration seems to be fine in the short term. Top marathon runners sweat more than 3.5 litres per hour. They replace nowhere near this much. If our performance drastically drops when we lose 2% of our body weight, how did Gebrselassie become an Olympic champion when losing 10% of his body weight? That is not to say drinking to thirst is the perfect strategy for running a marathon: but it does seem to be fine for everyday life.

21 Lessons for the 21st Century

April 27th, 2020 | Books

21 Lessons for the 21st Century is a book by Yuval Noah Harari. It looks at the near future (the next century) and the challenges that society will have to face.

Chiefly, this revolve around info-tech and bio-tech. What will happen when the majority of jobs are automated? The workforce had power when labour was required. But, as the rich upgrade their bodies to become superhumans and machines can replace the working man, how will this restructure society?

I highly enjoyed his book Sapiens: A Brief History of Humankind.

This one was thought-provoking, but not what I expected. I went in thinking there would be 21 clearly defined points that gave me something to think about. In reality, it was more of a ramble through various ideas, each spilling into the next. Interesting, but perhaps not as clear as I hoped it would be.

How to fix missing activities in Ironman Virtual Club

April 26th, 2020 | Sport, Tech

If you’ve been doing the Ironman Virtual Club races, you may have run into the problem where some of your activities have not registered, and you’re stuck on 33% or 67%. Worse, it doesn’t tell you what was missing, so you have no idea what went wrong.

One of the most likely causes is that your activity was too long. For example, if you run 20km for a 10km race, Ironman Virtual Club will not count it. I ran into this when I ran 1.7km for the 1.5km run 1 of Ironman VR3. And things got worse for Ironman VR4. Last week, they announced on Facebook it would be a middle-distance event:

It didn’t occur to me to double-check the details when signing up, so I went out and did a 5km run and 90km bike ride, only to flip down in front of the TV to watch the VR4 Pro Challenge and realise they were only cycling 40km! By this point, I was in for the full thing, so I finished off with a 21km run on Sunday. But none of my activities had registered with Ironman Virtual Club, even though I had completed the distance (and then done it again).

If you are using Garmin Connect, here is how to fix it:

Download the FIT file from Garmin Connect, then go to Fit File Tools. Remove the section of the workout beyond your required distance. In this case, I deleted the last 50km my bike ride and then downloaded the modified FIT file. To allow me to re-upload it to Garmin Connect, I then used the time stamp modifier to make it look like a new activity.

If you have Strava connected to Ironman Virtual Club, you could also upload the modified versions direct to Strava from the Fit File Tools website.

If you’re using something other than Garmin Connect that doesn’t produce FIT files, you can download the GPX file and use a GPX editor, like WTracks, to make similar edits. You can trim the start and end with WTracks, but I’m not sure how to modify the timestamp.

Cadbury Dairy Milk Mixed Buttons research

April 26th, 2020 | Science

Cadbury produces a sharing bag of mixed chocolate buttons containing both milk and white buttons. As soon as you learn this exists you are probably thinking “are there equal numbers of each button in the bag?”

Do not worry. I have painstaking done the research. For months I have been analysing the frequency of each type of button in each bag to work out what the balance is. Finally, my research is ready to publish.

Here are the results:

A paired samples t-test to compare the number of milk and white buttons in each bag. There were more milk buttons (M = 55.38, SD = 1.30) than white buttons (M = 45.38, SD = 1.30).

Test for normality was run (p = 0.327) so Wilxin signed-rank was used (N = 8,

Virtual parkrun PB attempt

April 25th, 2020 | Sport

The lockdown seems like a good excuse to do some fast running. And, now that I have decided that I can live with the Nike Next%, I was eager to see if they really could reduce my 5km PB time. So, I decided to go out early Tuesday morning while it was still cool.

I felt crap when I got up. I didn’t think about abandoning, but I did think “remember this feeling for the next time you’re feeling crap, in case you ace it”. The weather was pretty good: nice and cool but there was also a strong headwind on the finishing straight.

I jogged up there but had to come down to a walk on Clarendon Road because the shoes were really digging into my feet. As I reached the top, it eased off a bit, and I figured it was going to hurt a lot anyway, so I might as well give it a go. After a few minutes sit down in the park, I counted down from 10 and set off.

My first kilometre came in at 4:08. After that, I had to back off a little as my chest started to burn. My previous PB was 22:06, so even on a great day, sub-21 was unlikely. Therefore, anything near 4:12 was acceptable. I settled in around the 4:20s, which I was fine with as even a 22:30 would show I could still run at around my best.

As each kilometre went by, where my watch said I was and where I knew the parkrun markers would be, drifted apart. I had specifically turned GLONASS on, as well as GPS, to get a more accurate reading but it was to no avail.

As I fit the final straight I smashed into the wind and felt like I was sprinting while simultaneously feeling like I was slowing down. I crossed roughly where the parkrun finish line is at 21:06, although I had to keep running to 21:29 until my watch registered 5km.

21:06

Which was one was correct? I’m going with the official parkrun course, which I assume they have carefully measured. It was a clear day, though, so there should have been a good satellite signal.

After the run, I collapsed on the grass and took 5-10 minutes before I could get up and walk again. Based on the parkrun line time, I was exactly 60 seconds faster than my previous PB. At 4%, the shoes would give me 53 seconds. That means I was the other 7 seconds of improvement. Or at 5%, 67 seconds, in which case I lost 7 seconds. But either way, my fast running is still in good shape. Of course, it is easier without the crowds, too.

And that’s the story of how I got up before 9am for the first time since the lockdown started.