Publications by Jonathan Carroll
These Languages are Accumulating
I keep saying that the more programming languages you know, the more you will understand all the others you know – I’m now at the point where I want to solve every problem I see in a handful of different languages. They all offer different functionality, and some are certainly more suited to particular problems than others, but there’s a worl...
5743 sym Python (6708 sym/21 pcs)
Polyglot Maxxie and Minnie
Continuing my theme of learning all the languages, I took the opportunity of a programming puzzle to try out the same approach in a handful of different languages to compare how they work. For an upcoming APL’ers meetup the challenge was set as posed at the end of in this post, namely Maxxie and Minnie The maxxie of a number n is the largest num...
8122 sym Python (8187 sym/10 pcs) 14 img
Monads in R
In this post I describe a useful programming pattern that I implemented, and hopefully provide a gentle introduction to the idea of monads. The motivation for all of this was that I had a {dplyr} pipeline as part of a {shiny} app that queries a database and I wanted to “record” what steps were in that pipeline so that I could offer them as a wa...
10915 sym R (12382 sym/27 pcs) 4 img
A Safe Space for Learning How to Make Pull Requests
As October rolls around once more, the term Hacktoberfest might pop across your feeds; an effort aiming to encourage people to contribute to open-source software, particularly if they’re new to that. In this post I’ll describe what I’m offering towards that goal. Hacktoberfest has been running since (I think) 2017 and I’ve participated in a...
6428 sym R (3726 sym/1 pcs) 4 img
In-Place Modifications
In this post I explore some differences between R, python, julia, and APL in terms of mutability, and try to make something that probably shouldn’t exist. I watched this code_report video which describes a leetcode problem; You are given an integer array nums, an integer k, and an integer multiplier. You need to perform k operations on nums. In ...
6544 sym R (8785 sym/25 pcs)
Side by Side Comparison – Gleam vs R
Gleam vs R I thoroughly dislike ‘hot takes’ comparing programming languages based solely on a “feel” or differential familiarity (“I know this one better therefore it is better) so when I came across a blog post detailing a small learning project written in Gleam I wanted to understand what advantages and disadvantages that language brin...
18911 sym R (13727 sym/34 pcs) 10 img
IPv4 Components in APL
At a recent APL-focussed Meetup someone posed a challenge to slice up the components of an IPv4 address with an APL language and it prompted me to learn a bit more about how that works in general and how I could do the processing in APL myself. The person who posed the challenge had approached it themselves using J which I’m only vaguely familiar...
6399 sym R (7487 sym/26 pcs)
Tidy DataFrames but not Tibbles
A while ago (2019 seems so long ago now) I started working on something I thought was interesting but which never really got any traction. It has potential once more, so it’s about time I wrote up what it does and why I think it’s a useful idea. I’m going to talk about using the {dplyr} package on some data with rows and columns, but we’re ...
15859 sym R (51913 sym/57 pcs) 2 img
{charcuterie} – What if Strings Were Iterable in R?
I’ve been using a lot of programming languages recently and they all have their quirks, differentiating features, and unique qualities, but one thing most of them have is that they handle strings as a collection of characters. R doesn’t, it has a “character” type which is 0 or more characters, and that’s what we call a “string”, but w...
5445 sym R (6476 sym/15 pcs) 8 img
Let’s Talk About the Weather
A while ago I made some plots I really liked, but I never made a blog post about them. Then the data source stopped working and I couldn’t make them again. Now there’s a new data source, so it’s time for a post about some weather data! Way back in the mid 2010s I was interested in getting my hands on some weather data to answer a question I h...
8278 sym R (14449 sym/14 pcs) 12 img