Programming Leftovers
-
Working with Rust in (neo)vim | nicholas@web
I've been using vim for nearly as long as I've been writing code. My first introduction to it was being thrown in the deep end in 2009 by my Intro to CS lab assistant, who told us to write our programs using vi1 on the department servers. Why he told us that, I have no idea. But I got used to switching into and out of insert mode, and also how to save and quit.
At my internship in 2011, I learned to use vim in earnest. The project I worked on thrashed system memory by running HBase in a test suite over and over, and my work would routinely crash Eclipse2 as a result. I don't remember if my mentor suggested it or if I used vim on my own, but he did encourage it. He urged me to learn proper vim and disable the arrow keys to get used to navigating with the hjkl keys. That got me to learn it quickly through immersion and I fell in love.
-
How to Install Z Shell (Zsh) and Oh My Zsh on Linux
Z shell is an efficient, powerful, and interactive Unix shell. It's easy to install, configure, use, and learn on any Linux platform including Ubuntu, Fedora, Arch Linux, and more.
Here's how you can install Z shell and Oh My Zsh on your Linux machine.
-
The Fork Bomb: What it is, how it works, and where it originated
That simple line has been crashing systems in the Linux world for years — It is known as the (infamous) “BASH Fork Bomb”.
When run in a GNU/BASH shell, this BASH variant of the Fork Bomb will bring your average Linux system to its knees, lickety-split. A mere handful of characters that can cause a computer to cry “Uncle.”
But what, exactly, is a “Fork Bomb”? How do they work? And where on this green Earth of ours were they first created?
Come with me on a journey into the history, design, and usage of one of the most dastardly ideas in all of computing… of The Fork Bomb!
-
CircuitPython in 2023
Happy 2023! As the year starts, let’s take some time to share our goals for CircuitPython in 2023 and beyond. Just like past years (full summary 2019, 2020, 2021, and 2022), we’d like everyone in the CircuitPython community to contribute by posting their thoughts to some public place on the internet by Wednesday January 18th, 2023.
-
Modeling the secular trend in a stepped-wedge design - ouR data generation
Recently I started a discussion about modeling secular trends using flexible models in the context of cluster randomized trials. I’ve been motivated by a trial I am involved with that is using a stepped-wedge study design. The initial post focused on more standard parallel designs; here, I want to extend the discussion explicitly to the stepped-wedge design.
-
Progress on R-spatial evolution, Dec 2022
This is the second report on the R-spatial evolution project. The project involves the retirement (archiving) of rgdal, rgeos and maptools during 2023. The first report set out the main goals of the project. Here we report on progress so far, steps already taken, and those remaining to be accomplished. We feel that anyone planning training or teaching for the Northen hemisphere Fall semester/term should plan to have ceased using the retiring packages before work begins after the summer; sp will use sf for functions previously using retiring packages in June 2023.
-
Interpret Complex Linear Models with SHAP within Seconds - Michael’s and Christian's Blog
A linear model with complex interaction effects can be almost as opaque as a typical black-box like XGBoost.
XGBoost models are often interpreted with SHAP (Shapley Additive eXplanations): Each of e.g. 1000 randomly selected predictions is fairly decomposed into contributions of the features using the extremely fast TreeSHAP algorithm, providing a rich interpretation of the model as a whole. TreeSHAP was introduced in the Nature publication by Lundberg and Lee (2020).
-
Plotting two-way interactions from mixed-effects models using ten or six bins
Whereas the direction of main effects can be interpreted from the sign of the estimate, the interpretation of interaction effects often requires plots. This task is facilitated by the R package sjPlot (Lüdecke, 2022). In Bernabeu (2022), the sjPlot function called plot_model served as the basis for the creation of some custom functions. Two of these functions are deciles_interaction_plot and sextiles_interaction_plot. These functions allow the plotting of interactions between two continuous variables. In the case of deciles_interaction_plot, one of the variables is divided into ten bins, known as deciles, and the other variable is unchanged. In the case of sextiles_interaction_plot, one of the variables is divided into six bins, or sextiles, and the other variable is unchanged.
-
New Statistics Tutorial | Mad (Data) Scientist [Ed: Sadly outsourced to Microsoft proprietary software/prison]
It is not just a quick introduction, but a REAL one, a practical one. Even those who do already know statistics will find that they learn from this tutorial.
-
RObservations #44: Adding Frame and Custom Title Support To mapBliss - bensstats [Ed: Sadly, this one too helps Microsoft swallow R]
The mapBliss package is a R package which I developed which allows for users to make custom souvenir quality maps of their flights, road trips and favorite cities by utilizing the power of the leaflet and other R packages (for a full list, see the Github README here).
-
Seasonal emojis for your personal website | James' Coffee Blog
Before Christmas, I decided to work on a small project that would automatically change the emoji on my website. I am calling this project seasonal.js. Using seasonal.js, you can change all of the emojis on a web page that use a pre-defined CSS class. seasonal.js contains a default JSON object of various events that are relevant to me, from my birthday (assigned a party emoji) to Boxing Day (assigned a box emoji). You can change this object to include events that you want to celebrate on your website.
-
Day 9 (Advent of Code 2022)
The Advent of Code is not a sprint: it's a marathon: sometimes you've got to stop and smell the roses.
-
Day 11 (Advent of Code 2022)
In that one, we have to apparently cosplay as an IBM mainframe and just.. crunch them numbers. This doesn't look fun, and I can't think of a clever twist to make it fun, so let's try to make it short and sweet.
-
The Next-Generation Universal Hlang compiler
In a world where simple tasks have hundreds of dependencies and most of them are not documented, everything falls to chaos. The monolithigarchy dictates that your build times must be slow so that They (the dependocracy) can win over your hearts and minds with video games that you play during your compile times. One person gets mad about their string padding library being used by corporations without paying and then the entire internet explodes for a few days. This is unsustainable.
-
Some notes to myself on 'git log -G' (and sort of on -S)
Today I found myself nerd-sniped by a bit in Golang is evil on shitty networks (via), and wanted to know where a particular behavior was added in Go's network code. The article conveniently identified the code involved, so once I found the source file all I theoretically needed to do was trace it back in history. Until recently, my normal tool for this is Git's 'blame' view and mode, often on Github because Github has a convenient 'view git-blame just before this commit', which makes it easy to step back in history. Unfortunately in this case, the source code had been reorganized and moved around repeatedly, so this wasn't easy.