Over the last 6 months, I have been learning Racket in my free time. One of my first posts on this blog laid out my reasons for choosing Racket.
In a previous post, I used GUI toolkits to make progress bars in R and Racket. However, I usually prefer the ASCII progress bars of the progress package in R.
As an impatient person and an insecure programmer, I typically use progress bars for any code that takes more than a few minutes to run.
In learning about reading CSV files in Racket, I have started to reconsider whether storing small(ish) datasets in CSV files is the best default behavior.
In a previous post, I wrote about reading and writing data to file while retaining the structure and attributes of the data (i.
In a previous post, I wrote a function to perform repeated timings of untyped and typed versions of the same Racket functions.
In a previous post, I wrote that Racket’s if is similar to ifelse in R. That’s not quite right. This is a short post to clarify the comparison.
On my journey to learn Racket, I look for small pieces of R code to try to implement in Racket.
R makes it easy to generate random numbers from a wide variety of distributions with a consistent interface. For example, runif, rnorm, and rpois generate random numbers from uniform, normal, and Poisson distributions, respectively.
When programming in R, I generally pass data around by reading and writing text files (typically, CSV files). The ubiquity of CSV files means that many different types of software will open them easily (e.
When building a simulation model in R, I might want to group related input parameters into a data structure. For example, in a life cycle model with resident and anadromous fish, you might use different fecundity parameters for each life history type.
I have recently started learning Racket. For a first task, I tried to build a simple age-structured population model. I hit a stumbling block and reached out to the helpful folks on the Racket mailing list.