Nan Xiao
@nanxstats.bsky.social
Statistician | Co-author of https://r4csr.org/ + https://pycsr.org/ | Opinions = Mine
Żmij for R: Floating-point to string conversion with round-trip guarantees nanx.me/blog/post/zm...
Żmij for R: Floating-point to string conversion with round-trip guarantees
zmij converts doubles to the shortest decimal strings that parse back to exactly the same values. It brings Victor Zverovich's fast dtoa algorithm to R via Rust and extendr.
nanx.me
Building a Homebrew tap to distribute my software nanx.me/blog/post/ho...
Building a Homebrew tap to distribute my software
I built a Homebrew tap that distributes my fonts and CLI tools, so you can install everything with brew install. Here is why I made it, what's inside, and some honest notes on the Homebrew developer e...
nanx.me
Introducing bisectrunk: Parallel Git bisection for real-world regressions nanx.me/blog/post/bi...
Introducing bisectrunk: Parallel Git bisection for real-world regressions
bisectrunk is a Rust CLI for parallel Git bisection of real-world software regressions. It treats every candidate commit as an isolated, cached, resumable experiment, so you can trace a behavior chang...
nanx.me
Two small Python automation tools: asciilint and playwright-byob nanx.me/blog/post/as...
Two small Python automation tools: asciilint and playwright-byob
I'm happy to share two new Python tools: asciilint, a minimal, CI-friendly CLI for character policy checks in text files, and playwright-byob, a tiny helper for launching Playwright against the Chrome...
nanx.me
Anthrosevka Mono: Custom Iosevka build inspired by Anthropic Mono nanx.me/blog/post/an...
Anthrosevka Mono: Custom Iosevka build inspired by Anthropic Mono
A custom Iosevka build inspired by the look and feel of Anthropic Mono.
nanx.me
ggsci 5.0.0 and py-ggsci 2.0.0: Generative Color Scales from Gephi nanx.me/blog/post/gg... #rstats
ggsci 5.0.0 and py-ggsci 2.0.0: Generative Color Scales from Gephi
ggsci 5.0.0 introduces generative color palettes from Gephi. Instead of a fixed list of colors, you get a recipe: define the mood, ask for as many colors as you need, and the palette grows with your d...
nanx.me
Introducing pytest-r-snapshot: Verifying Python code against R outputs at scale nanx.me/blog/post/py...
Introducing pytest-r-snapshot: Verifying Python code against R outputs at scale
pytest-r-snapshot is a pytest plugin for snapshot testing Python code against reference outputs from R. It enables a portable workflow where you record snapshots locally with R, then replay them every...
nanx.me
Reverse dependency checking {data.table} now only takes 2 hours 44 minutes on a 256-core cloud instance: nanx.me/blog/post/re... #rstats #rust
revdeprun 2.1.0: hunting bottlenecks and a new speedrun record
revdeprun 2.1.0 tackles three bottlenecks in the reverse dependency checking workflow: pak's install scheduler, tarball downloads, and package builds. The result? A new speedrun record: 2 hours 44 min...
nanx.me
Reverse dependency check speedrun: a data.table case study nanx.me/blog/post/re... #rstats
Reverse dependency check speedrun: a data.table case study
How fast can you run reverse dependency checks for a package with 1700+ reverse dependencies? I put revdeprun to the test with data.table on a 48-core cloud instance. Here is what I learned about spee...
nanx.me
revdeprun: Rust CLI for #rstats package reverse dependency check automation nanx.me/blog/post/re...
revdeprun: Rust CLI for R package reverse dependency check automation
revdeprun is a Rust CLI tool that makes running reverse dependency checks on cloud instances as easy as a single command. Learn why this matters for R package maintainers and how it can save you hours...
nanx.me
Introducing py-ggsci: ggsci color palettes for plotnine in Python nanx.me/blog/post/gg...
Introducing py-ggsci: ggsci color palettes for plotnine in Python
Bring publication-ready color palettes to your Python plots with py-ggsci. This new package ports the popular ggsci palettes from R to plotnine and makes it easy to create beautiful, professional visu...
nanx.me
pkgdown.offline: Build pkgdown websites without an internet connection nanx.me/blog/post/pk... #rstats
pkgdown.offline: Build pkgdown websites without an internet connection
Introducing pkgdown.offline, an R package for building pkgdown websites entirely offline. Learn how it addresses recent pkgdown internet requirements, essential for CI/CD pipelines and air-gapped envi...
nanx.me
Customizing Inter with alternative optical sizing presets nanx.me/blog/post/in...
Customizing Inter with alternative optical sizing presets
Fine-tune the popular Inter typeface using optical sizing (opsz) and letter spacing. This post introduces a set of CSS presets to easily adjust its appearance for optimal readability in your web proje...
nanx.me
Optimize R foreach loops for parallelism: avoid the .combine argument nanx.me/blog/post/r-... #rstats
Optimize R foreach loops for parallelism: avoid the .combine argument
Learn why using .combine in R parallel foreach loops can harm performance. Benchmark comparisons show that manual aggregation methods like data.table::rbindlist() significantly accelerate execution.
nanx.me
Prevent RStudio 2024.12.0 from adding ProjectID to .Rproj files nanx.me/blog/post/rs... #rstats
Prevent RStudio 2024.12.0 from adding ProjectID to .Rproj files
RStudio 2024.12.0 unconditionally adds a ProjectID field to .Rproj files, causing unwanted Git diffs and potential editing conflicts. This post explains the issue and provides an R script to automatic...
nanx.me
Customize testthat snapshot directory with monkey patching nanx.me/blog/post/te... #rstats
Customize testthat snapshot directory with monkey patching
Learn how to customize the default snapshot directory in testthat using monkey patching in R. This post provides a practical solution for modifying testthat internals to meet your project's needs, wit...
nanx.me