<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>R packages on Nan Xiao | 肖楠</title>
    <link>https://nanx.me/tags/r-packages/</link>
    <description>Recent content in R packages on Nan Xiao | 肖楠</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    <lastBuildDate>Wed, 09 Sep 2026 11:39:00 +0000</lastBuildDate>
    <atom:link href="https://nanx.me/tags/r-packages/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>shinygenui: Generative UI for Shiny</title>
      <link>https://nanx.me/blog/post/shinygenui/</link>
      <pubDate>Wed, 09 Sep 2026 11:39:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/shinygenui/</guid>
      <description>Sketched user interface skeletons. Procedurally generated with p5.brush.skeleton. It’s my pleasure to share that shinygenui is now on CRAN. It brings generative UI to Shiny: the developer defines a catalog of components, and a language model builds and updates an interface as users describe what they need.&#xA;You can install it with:&#xA;install.packages(&amp;quot;shinygenui&amp;quot;) Or get the development version from GitHub:&#xA;pak::pak(&amp;quot;nanxstats/shinygenui&amp;quot;) Apparently, language models are unsupervised multitask learners, but that’s so 2019.</description>
    </item>
    <item>
      <title>okr: Reproducible R source context for coding agents</title>
      <link>https://nanx.me/blog/post/okr/</link>
      <pubDate>Mon, 17 Aug 2026 21:53:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/okr/</guid>
      <description>Photo by @tanyabarrow. Today I’m pleased to introduce okr, a small Rust CLI for giving coding agents reproducible source context from R packages and other reference repositories.&#xA;Recent coding agents can solve surprisingly hard problems when they can inspect the relevant code. My own workflows kept running into one specifically R-shaped problem: after an R package is installed, R functions live in binary .rdb and .rdx databases, while compiled code from the source package under src/ disappears.</description>
    </item>
    <item>
      <title>Żmij for R: Floating-point to string conversion with round-trip guarantees</title>
      <link>https://nanx.me/blog/post/zmij-r/</link>
      <pubDate>Sun, 09 Aug 2026 22:21:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/zmij-r/</guid>
      <description>Photo by Claire Satera. Stylized with Paper Shaders halftone dots filter. I’m glad to share that zmij is now on CRAN. zmij converts doubles to decimal strings and back, using the fewest digits needed to recover the original values. It brings Victor Zverovich’s zmij algorithm to R, via David Tolnay’s Rust zmij port, wrapped in a vectorized interface with extendr.&#xA;You can install it from CRAN with:&#xA;install.packages(&amp;quot;zmij&amp;quot;) Why bother?</description>
    </item>
    <item>
      <title>ggsci 5.0.0 and py-ggsci 2.0.0: Generative Color Scales from Gephi</title>
      <link>https://nanx.me/blog/post/ggsci-5-0-0/</link>
      <pubDate>Sun, 19 Apr 2026 01:33:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/ggsci-5-0-0/</guid>
      <description>San Francisco 1.4. Photo by Pine Watt. After the last major version update in September 2025, I am happy to announce the release of ggsci 5.0.0 and ggsci for Python 2.0.0.&#xA;You can install the R package ggsci from CRAN:&#xA;install.packages(&amp;quot;ggsci&amp;quot;) And install the Python package from PyPI:&#xA;pip install ggsci What’s new Every color palette in ggsci until now has been a fixed list: someone chose those exact colors, arranged them in a particular order, and you used them as-is.</description>
    </item>
    <item>
      <title>revdeprun 2.1.0: hunting bottlenecks and a new speedrun record</title>
      <link>https://nanx.me/blog/post/revdeprun-2-1-0/</link>
      <pubDate>Wed, 24 Dec 2025 19:01:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/revdeprun-2-1-0/</guid>
      <description>A race car pit crew in action during a pit stop. Photo by Paul Krüger. I’m excited to announce revdeprun 2.1.0, a major update to my Rust CLI tool for automating R package reverse dependency checks. This release is really two updates in one: version 2.0.0 accelerated dependency installation, while 2.1.0 addressed two more bottlenecks I discovered during testing. The combined result is a much faster workflow from start to finish.</description>
    </item>
    <item>
      <title>Reverse dependency check speedrun: a data.table case study</title>
      <link>https://nanx.me/blog/post/revdep-speedrun/</link>
      <pubDate>Wed, 05 Nov 2025 08:51:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/revdep-speedrun/</guid>
      <description>Monument Valley Navajo Tribal Park. Photo by Elvis Liang. A week ago, I announced revdeprun, a Rust CLI tool for automating R package reverse dependency checks. Since then, I have been iterating rapidly: 16 crates.io releases in a week! These updates focused on both correctness and speed. The tool has evolved from its initial v0.1.0 to v1.4.2, and the workflow now leverages pak for dependency resolution and xfun for the checking1.</description>
    </item>
    <item>
      <title>revdeprun: Rust CLI for R package reverse dependency check automation</title>
      <link>https://nanx.me/blog/post/revdeprun/</link>
      <pubDate>Mon, 27 Oct 2025 17:42:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/revdeprun/</guid>
      <description>Smoke and speed: a race car mid-drift on the track. Photo by Jack Stapleton. Update (2025-10-31): revdeprun 1.0.0 switched to using a custom workflow to pre-install binary dependencies for checking reverse dependencies, and run parallel checks using xfun::rev_check(). This significantly improves performance and reliability. Read the release notes here. This post has been updated to reflect these changes.&#xA;I’m glad to announce the release of revdeprun, a Rust CLI tool that makes it easy to run reverse dependency checks on cloud instances1.</description>
    </item>
    <item>
      <title>ggsci 4.0.0: 400&#43; new color palettes</title>
      <link>https://nanx.me/blog/post/ggsci-4-0-0/</link>
      <pubDate>Thu, 25 Sep 2025 23:36:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/ggsci-4-0-0/</guid>
      <description>Cozy autumn vibes: a warm drink, a good book, and colorful leaves. Photo by Alisa Anton. After the last update in June 2024, I am excited to announce the release of ggsci 4.0.0 and ggsci for Python 1.0.0. You can install the R package ggsci from CRAN:&#xA;install.packages(&amp;quot;ggsci&amp;quot;) And install the Python package from PyPI:&#xA;pip install ggsci This update brings over 400 new discrete color palettes for ggplot2 and plotnine visualizations.</description>
    </item>
    <item>
      <title>pkgdown.offline: Build pkgdown websites without an internet connection</title>
      <link>https://nanx.me/blog/post/pkgdown-offline/</link>
      <pubDate>Sat, 10 May 2025 01:02:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/pkgdown-offline/</guid>
      <description>On the grid but off the line. Logo font: Founders Grotesk Condensed Semibold. I’m pleased to announce that the R package pkgdown.offline is now available on CRAN. You can install it with:&#xA;install.packages(&amp;quot;pkgdown.offline&amp;quot;) pkgdown.offline enables you to build pkgdown websites in environments without internet access, such as private, restricted development workflows or CI/CD pipelines. It achieves this by bundling the essential frontend assets (CSS, JavaScript) that pkgdown typically fetches online and by providing alternative implementations for key pkgdown functions like init_site() and build_site().</description>
    </item>
    <item>
      <title>R packages using Rust</title>
      <link>https://nanx.me/blog/post/r-rust-pkgs/</link>
      <pubDate>Fri, 28 Feb 2025 16:37:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/r-rust-pkgs/</guid>
      <description>TL;DR: I’m curating a list of CRAN R packages that use Rust: nanxstats/r-rust-pkgs.&#xA;Dirt bike. Photo by POWERING OFFROAD. Rust in R packages Rust has been the most admired programming language for nearly a decade. CRAN, the largest public repository for R packages, has also supported integrating Rust in R packages for several years. What’s the magic behind the language?&#xA;To me, Rust is a great choice for writing high-performance extensions for both R and Python, offering memory safety and a strong ecosystem.</description>
    </item>
    <item>
      <title>R command-line tool paths on Windows</title>
      <link>https://nanx.me/blog/post/r-windows-paths/</link>
      <pubDate>Sun, 15 Sep 2024 19:28:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/r-windows-paths/</guid>
      <description>Mirror House. Photo by Karsten Winegeart. I’m glad to share a new repository that documents the essential R command-line tool paths on Windows: https://github.com/nanxstats/r-windows-paths.&#xA;Motivation As an R developer, I frequently set up new development and testing environments for my R packages on Windows. This process often involves installing several command-line tools alongside R, including but not limited to:&#xA;Rtools: Compiles C/C++/Fortran code. TinyTeX: Compiles reference manual and PDF vignettes.</description>
    </item>
    <item>
      <title>ssw is on CRAN</title>
      <link>https://nanx.me/blog/post/ssw-0-2-0/</link>
      <pubDate>Sun, 08 Sep 2024 19:07:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/ssw-0-2-0/</guid>
      <description>Cape Cod sand dunes on a cloudy day. Photo by Nicholas Bartos. I’m excited to share that my R package ssw is now available on CRAN. This package began as a weekend project in 2020. ssw offers an R interface for SSW (Zhao et al. 2013), a high-performance C/C++ implementation of the Smith-Waterman algorithm for sequence alignment using SIMD.&#xA;You can install ssw from CRAN with:&#xA;install.packages(&amp;quot;ssw&amp;quot;) For clarity, I will refer the R package as ssw-r from now on.</description>
    </item>
    <item>
      <title>ggsci 3.2.0: new color palettes from Observable, Bootstrap, and Tailwind CSS</title>
      <link>https://nanx.me/blog/post/ggsci-3-2-0/</link>
      <pubDate>Sat, 06 Jul 2024 00:20:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/ggsci-3-2-0/</guid>
      <description>Villa in Zurich, perspective view. From “Moderne Architektur” (Modern Architecture), edited by Lambert &amp;amp; Stahl, Stuttgart, 1891. Scan from Europeana. I am delighted to announce the release of ggsci 3.2.0. The R package ggsci was first released in 2016. It offers a range of ggplot2 color scales drawn from various sources, including scientific publications, data visualization tools, sci-fi movies, and television series.&#xA;To install ggsci from CRAN, use:&#xA;install.packages(&amp;quot;ggsci&amp;quot;) As a follow-up to the ggsci 3.</description>
    </item>
    <item>
      <title>ggsci 3.1.0, ggsurvfit example, and reverse dependency check</title>
      <link>https://nanx.me/blog/post/ggsci-3-1-0/</link>
      <pubDate>Thu, 23 May 2024 00:30:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/ggsci-3-1-0/</guid>
      <description>Photo by Elena Mozhvilo. I am excited to announce the release of ggsci 3.1.0. ggsci is an R package that provides a collection of color palettes inspired by colors used in scientific journals, data visualization libraries, science fiction movies, and TV shows.&#xA;To install ggsci from CRAN, run:&#xA;install.packages(&amp;quot;ggsci&amp;quot;) This release introduces a new color scale and brings documentation improvements. This post demonstrates how to create a Kaplan-Meier plot using ggsurvfit, cowplot, and ggsci.</description>
    </item>
    <item>
      <title>msaenet 3.1.2 and a sparse survival modeling example</title>
      <link>https://nanx.me/blog/post/msaenet-3-1-2/</link>
      <pubDate>Sun, 12 May 2024 20:10:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/msaenet-3-1-2/</guid>
      <description>Father-Son Tennis. Photo by Lucas Davies. I’m pleased to announce that msaenet 3.1.2 is now available on CRAN.&#xA;You can install msaenet with:&#xA;install.packages(&amp;quot;msaenet&amp;quot;) If you frequently build sparse linear models, msaenet can help you generate more parsimonious solutions with adaptive estimations. It supports any number of adaptive estimation steps, flexible initialization methods, multiple model selection criteria, and automatic parallel parameter tuning.&#xA;New color palette This is a more focused update compared to the 3.</description>
    </item>
    <item>
      <title>stackgbm is on CRAN</title>
      <link>https://nanx.me/blog/post/stackgbm-0-1-0/</link>
      <pubDate>Tue, 30 Apr 2024 08:10:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/stackgbm-0-1-0/</guid>
      <description>A group of sheep on Faroe Islands. Photo by Dylan Shaw. I’m happy to announce that stackgbm, a minimalist R package for tree model stacking, is now on CRAN. Model stacking is an ensemble learning method that combines the predictions from multiple base learners to improve overall performance. stackgbm makes it easy to stack gradient boosting decision tree (GBDT) models, which are particularly effective for classification tasks.&#xA;You can install stackgbm with:</description>
    </item>
    <item>
      <title>R Package Release Notes: ggsci, protr, and msaenet (Spring 2024)</title>
      <link>https://nanx.me/blog/post/ggsci-protr-msaenet-release-notes-2024/</link>
      <pubDate>Sun, 21 Apr 2024 19:00:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/ggsci-protr-msaenet-release-notes-2024/</guid>
      <description>Cute market in Rome, Italy. Photo by Mark Pecar. Maintaining R packages is a significant time and effort commitment. The Releasing to CRAN chapter of the R Packages book provides an excellent overview of the many responsibilities package authors face. Henrik’s CRANhaven also helps me appreciate the efforts made by both CRAN maintainers and package maintainers to keep a consistent, high standard on software quality and integration within a single, trusted repository.</description>
    </item>
    <item>
      <title>Prompt LLMs with R Package Source Code Using pkglite</title>
      <link>https://nanx.me/blog/post/pkglite-llm-prompt/</link>
      <pubDate>Thu, 28 Mar 2024 20:00:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/pkglite-llm-prompt/</guid>
      <description>Illustration from Google DeepMind. Artist: Martina Stiftinger. Sometimes, large language models (LLMs) answer coding questions by making up software behaviors or APIs that don’t exist. A simple but effective strategy to minimize such hallucination problems is to feed the exact, complete source code as context in the prompt. For code organized in R packages, it is tedious to copy the file contents and construct them into prompts manually. Fortunately, you can use pkglite to automate this process.</description>
    </item>
    <item>
      <title>protr 1.7-0</title>
      <link>https://nanx.me/blog/post/protr-1-7-0/</link>
      <pubDate>Fri, 10 Nov 2023 21:00:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/protr-1-7-0/</guid>
      <description>3D render from Google DeepMind. Artist: Wes Cockx. I am glad to announce the release of protr 1.7-0. Install it from CRAN with:&#xA;install.packages(&amp;quot;protr&amp;quot;) You can also install it from conda-forge in Python.&#xA;First released in 2012, protr was my very first open source R package. The package generates representations for protein sequences such as numerical features and similarity measures. Since its inception, protr has evolved after 21 CRAN releases by incorporating user feedback.</description>
    </item>
    <item>
      <title>Context-Free R Package Release Checklist Generation with usethis</title>
      <link>https://nanx.me/blog/post/r-package-release-checklist/</link>
      <pubDate>Mon, 12 Jun 2023 20:30:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/r-package-release-checklist/</guid>
      <description>The release checklist generation function described in this post is also available in this GitHub Gist.&#xA;Photo by David Marcu. Software release at scale An agile, automated, and reliable release process is a key component of continuous delivery for modern software engineering teams. In particular, releasing new versions of R packages often involves going through a sequence of manual and automated checks to ensure quality and compliance. To scale up such efforts within a development team, it is crucial to follow a consistent release checklist.</description>
    </item>
    <item>
      <title>Compressing PNG Output for R Packages with pngquant and ragg</title>
      <link>https://nanx.me/blog/post/rpkgs-pngquant-ragg/</link>
      <pubDate>Sun, 09 Apr 2023 00:30:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/rpkgs-pngquant-ragg/</guid>
      <description>Cassette collection. Photo by Jametlene Reskp. Introduction Dealing with large-scale image outputs in R packages can be challenging, especially when it comes to passing CRAN checks. In this post, I will share my experience in using pngquant and ragg to compress the PNG output size for readme and vignettes. This allows R packages with many figures in their documentation to pass the CRAN checks without compromising image quality.&#xA;Problem description I encountered a problem with my package, ggsci, which outputs approximately 30 example figures from both vignettes and README.</description>
    </item>
    <item>
      <title>New Paper Published: eCTD Submission with Analysis Using R</title>
      <link>https://nanx.me/blog/post/ectd-pkglite-paper/</link>
      <pubDate>Wed, 28 Sep 2022 11:30:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/ectd-pkglite-paper/</guid>
      <description>Photo by DeepMind.&#xA;I am thrilled to share that our paper, Electronic Common Technical Document Submission with Analysis Using R, is published online today in Clinical Trials. We have selected the open access (OA) option to ensure that everyone in the community can check out the full text freely.&#xA;A simple solution to a complex problem Our article presented a viable path to prepare proprietary R assets for submission, following the electronic common technical document (eCTD) specification.</description>
    </item>
    <item>
      <title>More Than 1,500 File Extensions Are Used Inside R Packages</title>
      <link>https://nanx.me/blog/post/cran-file-exts/</link>
      <pubDate>Wed, 01 Dec 2021 00:00:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/cran-file-exts/</guid>
      <description>The R code to reproduce the results is available from the GitHub repo nanxstats/cran-file-exts.&#xA;Photo by Pawel Czerwinski. When applied correctly, file extensions can be informative. They are the very first clue on handling a specific file without parsing the file content.&#xA;To properly capture and classify files in source R packages, I am interested in learning what file extensions are frequently used by R packages.&#xA;We can achieve this easily by downloading all R packages available from CRAN one at a time and collect the file extensions inside:</description>
    </item>
    <item>
      <title>Rebranding R Packages with Hexagon Stickers: A Minimalist Approach</title>
      <link>https://nanx.me/blog/post/rebranding-r-packages-with-hexagon-stickers/</link>
      <pubDate>Mon, 08 Feb 2021 01:30:00 +0000</pubDate>
      <guid>https://nanx.me/blog/post/rebranding-r-packages-with-hexagon-stickers/</guid>
      <description>A new hex sticker wall of my R packages. I have built a few R packages over the years. I have always been adding some forms of an ad hoc logo to them, trying to make a visual impression. As the portfolio size grows larger, I realized that I would need a principled way to create the logos and refresh my packages’ look. Hexagon stickers seem to be an acceptable form of logos that are heavily used by the R community.</description>
    </item>
  </channel>
</rss>
