Sign in

Josiah

@josiah.rs
2.7K followers 509 following 764 posts

putting R in production @ricochet.rs doing spatial stats @ Esri blog: josiah.rs

PostsRepliesMedia
Josiah @josiah.rs · 05/10/2026
and an instance wide view for all of your items—also, 👀 finally got around to supporting @jupyter.org notebooks. #databs #rstats anyways! a detailed post soon enough! super stoked 🙃🐇
120
Josiah @josiah.rs · 05/10/2026
reeeee feeling giddy about the next release of @ricochet.rs live monitoring of app (shiny in this case) processes—max ram, CPU, and connections.
a screenshot of ricochet's upcoming Running worker tab that shows CPU and RAM usage for runnin application worker
161
Josiah @josiah.rs · 03/10/2026
All my friend love {calcite}!! For the #rstats folks: github.com/R-ArcGIS/cal...
a screenshot of a shiny dashboard with inputs "X Axis" "Y Axis" and "Color by" showing a scatter plot of Bill length vs bill depth colored by species in  the main panel.
060
Josiah @josiah.rs · 01/10/2026
as an aside...why aren't we talking about {plumber2} as a full-stack web-dev approach??? 👇🏼 plumber for server-side-rendered websites is high key awesome gallery.ricochet.rs/app/penguins... #rstats
070
Josiah @josiah.rs · 25/09/2026
Using a similar approach of using GeoParquet and the new ArcGIS ParquetLayer support from we're getting good performance with {arcgizviz}—though still not quite 4 seconds! 😅 GeoParquet and GeoArrow are the future 🚀 #rstats #rspatial
120
Josiah @josiah.rs · 24/09/2026
I cannot emphasize enough how excited I am about {geoarrowwidget} and {deckglgeoarrow}. 3.2 **million** points in 4 seconds. #rspatial #rstats
4519
Josiah @josiah.rs · 24/09/2026
obligatory
020
Josiah @josiah.rs · 23/09/2026
not even a little bit spicy lol. I'm 30 now. Spice hurts my tummy www.reddit.com/r/rstats/com...
 would _really_ love to see collaboration between rv, rig, and rpx. Each of these tools are trying to solve a similar problem, but in their own bespoke way.

Ideally, if I could have my cake without baking it (thank you for your work!!!) I’d like to see all of these tool developers approach R core with a proposal for a canonical way of representing project dependencies so—at minimum, the same file format could be used across the tools.

Then perhaps a follow up that can go over how we can improve CRAN mirror structures to have more robust version deps version history etc so that everyone can leverage the same structure.
130
Josiah @josiah.rs · 17/09/2026
remember to `cargo clean` was wondering how my 1tb drive only had 300gb left...
cargo clean
Removed 269864 files, 463.1GiB total
161
Josiah @josiah.rs · 15/09/2026
Using {mirai} to absolutely throttle my machine to train Graph Neural Networks in parallel with {torchgnn) github.com/josiahparry/... #rstats
Screenshot of the activity monitor on my Macbook Pro showing 8 R processes each at 70% CPU with almost max CPU load.
2241
Josiah @josiah.rs · 12/09/2026
It looks like {geoarrowrs} is even competitive with {sedonadb}?! Do we got a new fast spatial contender! #rstats josiahparry.github.io/geoarrowrs/a...
Graph of bench marks for geoarrow-rs vs duckspatial and sedonda-db
2231
Josiah @josiah.rs · 11/09/2026
{geoarrowrs} is very competitive with {duckspatial} and even when calculating the **correct** distances on geodesic data #rspatial
Bench mark of geoarrowrs vs duckspatial of the below table

op	n	geoarrowrs	sf	duckspatial	geoarrowrs (geodesic)
join	100,000	0.023	0.663	0.333	NA
join	1,000,000	0.108	6.596	0.362	NA
join	3,000,000	0.288	22.973	1.034	NA
filter	100,000	0.017	0.761	0.335	NA
filter	1,000,000	0.070	7.705	0.359	NA
filter	3,000,000	0.197	27.487	0.971	NA
intersects	100,000	0.008	0.743	0.335	NA
intersects	1,000,000	0.041	7.708	0.563	NA
intersects	3,000,000	0.145	25.076	2.071	NA
dissolve	100,000	0.107	0.464	0.306	NA
dissolve	1,000,000	0.373	4.755	0.447	NA
dissolve	3,000,000	1.161	16.884	1.498	NA
distance	1,000	0.017	0.283	0.315	0.059
distance	5,000	0.129	6.766	1.968	1.487
distance	10,000	0.572	30.196	8.367	6.484
0194
Josiah @josiah.rs · 10/09/2026
_geodesic_ distance between 6 million points in < 2 seconds in {geoarrowrs} Its under 1 second for euclidean distances... Arrow + GeoArrow + Rust + R = vrooooom! github.com/JosiahParry/... #rstats
1382
Josiah @josiah.rs · 25/08/2026
what hardware are you cooking this on lol?! Absolutely crushing my mbp m5 16gb ram lol!
130
Josiah @josiah.rs · 25/08/2026
Written with 🦀 Rust and extendr! And holy SMOKES its cooking on my machine!!! Be careful lol! {freestiler} WILL make use of your machine 🚀 #rstats
020
Josiah @josiah.rs · 25/08/2026
We got interactive selections working... Might be close to time to tidy this up and try shipping an initial version to CRAN. #rspatial #rstats
060
Josiah @josiah.rs · 23/08/2026
We getting mappy up in here! Maybe the package should be called `{arcmap}` /s 😅🙈 #rstats #rspatial #gischat
181
Josiah @josiah.rs · 20/08/2026
reeeee 🙀 next up? maps! 🗺️ #rstats
050
Josiah @josiah.rs · 18/08/2026
babysteppin our way there! r.esri.com/arcgisviz/re... Once basic charts are complete we'll tackle the shiny integration
Bar chart titled "Penguins by sex and island" showing count by sex for each island in the palmer penguins dataset.

Code: 


arc_bar(penguins, island) |>
  set_color(sex, palette = "Watermelon Sugar") |> 
  set_labs(title = "Penguins by sex and island", x = NULL, y = NULL) |> 
  set_flipped()
121
Josiah @josiah.rs · 18/08/2026
Progress...Composable web graphics from the ArcGIS Maps SDK -> R inbound 🐇 #rstats
library(arcgisviz)

arc_chart(penguins) |>
  set_type("bar") |>
  set_x(species) |>
  set_y(body_mass) |>
  set_stat("mean") |>
  set_color(species, palette = "Watercolor Surprise") |>
  set_labs(
    title = "Palmer penguins",
    subtitle = "Mean body mass by species",
    x = "Species",
    y = "Mean body mass (g)"
  )
071
Josiah @josiah.rs · 15/08/2026
they must've been watching Legend of Korra recently.
000
Josiah @josiah.rs · 15/08/2026
New web charting 📦 in the works 👀 #rstats One line `arcgisviz::arc_scatter(penguins, bill_len, flipper_len)`
scatter plot of bill_len vs flipper_len with a hover tooltip of a single point.
0110
Josiah @josiah.rs · 15/08/2026
i'm never fixing this typo no matter how many people have asked me.
Screenshot of my blog post titled "Apache Arrow, Rust, and cross-langauge data science" with the typo highlighted
020
Josiah @josiah.rs · 09/08/2026
Spotify is giving out free access to Claude, it seems.
1150
Josiah @josiah.rs · 12/07/2026
010
Josiah @josiah.rs · 10/07/2026
Aight, we now geocoding from an ArcGIS Portal Item in the browser.... Thats enough for a demo app I think? #rstats #arcgis #gischat
010
Josiah @josiah.rs · 09/07/2026
Nothing like a 🚨 conf deadline to kick you right in the pants 🦵👖 to make cool demo material! Materials will be at: github.com/R-ArcGIS/202...
180
Josiah @josiah.rs · 08/07/2026
dude, this is sick!!!!! #rstats
1152
Josiah @josiah.rs · 07/07/2026
New 📦 {arcgisrouting} on CRAN! • Get directions 🗺️ • Generate travel times ⏱️ • Solve fleet routing 🚛 For the #ArcGIS ↔️ #rstats users: 🚨 These services consume credits cran.r-project.org/web/packages...
library(sf)
library(arcgisutils)
library(arcgisrouting)

set_arc_token(auth_user())

stops <- st_sf(
  name = c("Start", "Middle", "End"),
  geometry = st_sfc(
    st_point(c(-122.4194, 37.7749)),  # San Francisco
    st_point(c(-122.0312, 37.3318)),  # Cupertino
    st_point(c(-121.8863, 37.3382)),  # San Jose
    crs = 4326
  )
)

resp <- find_routes(stops)

# print the directions
resp$directions |> 
  tidyr::unnest(directions) |> 
  dplyr::select(length, time, text)
#> # A tibble: 22 × 3
#>     length   time text                                                          
#>      <dbl>  <dbl> <chr>                                                         
#>  1  0       0     Start at Start                                                
#>  2  0.148   0.828 Go northeast on Market St toward Van Ness Ave / S Van Ness Ave
#>  3  0.603   2.44  At the traffic light, turn right on 10th St                   
#>  4 34.9    36.4   Bear left to merge onto US-101 S toward San Jose              
#>  5  5.29    5.45  Take exit 398B on the right to merge onto CA-85 S toward Cupe…
#>  6  0.152   0.152 Take the exit on the right to I-280 toward San Jose / San Fra…
#>  7  1.48    1.48  Keep left at the fork to merge onto I-280 S toward San Jose   
#>  8  0.230   0.793 Take exit 11 on the right to De Anza Boulevard                
#>  9  0.240   0.766 At the traffic light, turn right on N De Anza Blvd            
#> 10  0.0996  0.209 At the traffic light, make a U-turn and go back on N De Anza …
#> # ℹ 12 more rows
194
Josiah @josiah.rs · 29/06/2026
Am i crazy or should `scale_viridis_d()` work with integers because they're discrete values? #rstats

Error in `scale_fill_viridis_d()` at 2026-06-22/R/dev-block-grid.R:21:1:
! Continuous value supplied to a discrete scale.
ℹ Example values: 5, 6, 3, 4, and 1.

Show Traceback
240
Josiah @josiah.rs · 06/06/2026
there's this type of masochism in the dev community where they just love spending 1-4 hours a day updating things. As if being on the bleeding edge is actually the best place to be! Ay carumba!
110
Josiah @josiah.rs · 21/05/2026
fwiw the example of "where toml strains" can be rewritten with a single heading. The YAML 1.2 spec feels like we're 270° and just oneee more step to getting back to json as the "best" format! 🤣
[services]
web = {
  image = "nginx:latest",
  environment = { DB_HOST = "postgres", DB_PORT = 5432 },
  resources = {
    limits = { memory = "512M", cpu = "0.5" }
  }
}
230
Josiah @josiah.rs · 20/05/2026
» arrow-extendr « now supports geoarrow 🌏 Use geoarrow types from anywhere in your 🦀 Rust-powered R packages 🐇📦 👈🏼 Centroid using geoarrow + extendr 👉🏼 called from R compared to {sf} #rust #rstats
use anyhow::bail;
use arrow_extendr::FromArrowRobj;
use extendr_api::prelude::*;
use geo_traits::{CoordTrait, PointTrait};
use geoarrow::array::{GeoArrowArrayAccessor, PointArray};

#[extendr]
fn geoarrow_centroid(x: Robj) -> anyhow::Result<Doubles> {
    let res = PointArray::from_arrow_robj(&x)?;

    let (sum_x, sum_y, n) = res.iter_values().filter_map(|xi| xi.ok()).fold(
        (0.0_f64, 0.0_f64, 0usize),
        |(sx, sy, n), v| {
            let (x, y) = v.coord().unwrap().x_y();
            (sx + x, sy + y, n + 1)
        },
    );

    if n == 0 {
        bail!("cannot compute centroid of empty array");
    }

    let res = [sum_x / n as f64, sum_y / n as f64]
        .map(Rfloat::from)
        .into_iter()
        .collect::<Doubles>();

    Ok(res)
}library(wk)
library(geoarrow)
devtools::load_all()
#> ℹ Loading extendrtest

pnts <- wk::xy(rnorm(100, -180, 180), runif(100, -90, 90))
x <- geoarrow::as_geoarrow_array(pnts)

geoarrow_centroid(x)
#> [1] -182.711392   -2.806439
sf::st_as_sfc(pnts) |> 
  sf::st_combine() |> 
  sf::st_centroid()
#> Geometry set for 1 feature 
#> Geometry type: POINT
#> Dimension:     XY
#> Bounding box:  xmin: -182.7114 ymin: -2.806439 xmax: -182.7114 ymax: -2.806439
#> CRS:           NA
#> POINT (-182.7114 -2.806439)
1175
Josiah @josiah.rs · 06/05/2026
Behold, ye vibers! The promise land (the docs) await you!
080
Josiah @josiah.rs · 06/05/2026
turns out im too poor to know how poor i am
100
Josiah @josiah.rs · 04/05/2026
Left: the result when running from the interpreter Right: quarto render So frustrating lol
100
Josiah @josiah.rs · 04/05/2026
essentially this but with patchwork stackoverflow.com/questions/15...
120
Josiah @josiah.rs · 04/05/2026
Why can't I do this 😭 #rstats
  ggplot() +
    geom_sf(data = nodes[c(i, nb[[i]])]) +
    geom_sf(data = nodes[i, ])
251
Josiah @josiah.rs · 21/04/2026
040
Josiah @josiah.rs · 10/04/2026
✨ CRAN non-API 📦 package checks via GitHub action and {plumber} API 👨🏻‍🔧 Changes keep coming left and right and I can't keep up! github.com/JosiahParry/... #rstats
Screenshot of a failed github action workflow "Check for non-API calls."
Text output:

Run RESPONSE=$(curl -sf "https://dev.vm.ubuntu.ricochet.rs/app/non-api-checks/check?pkg=$PKG_NAME")
{
  "last_updated": "2026-04-10 17:52:44 CEST",
  "has_non_api_calls": true,
  "symbols": [
    "R_UnboundValue"
  ]
}
Error: non-API calls detected in b64
Error: Process completed with exit code 1.
1101
Josiah @josiah.rs · 01/04/2026
Her favorite thing is warm laundry.
0100
Josiah @josiah.rs · 27/03/2026
hah! Please, read the Holy Scripture™ Advanced R! adv-r.hadley.nz I'd argue macro support in R is already there and has been for a **long** time!! via {rlang} and environment, sym and quo magic! For example macro_fun() creates a function square2() in the caller environment (code in alt) #rstats
library(rlang)

macro_fun <- function(name) {
  f <- new_function(alist(x=), quote(x^2))
  nm <- sym(name)
  env_bind(caller_env(), !!nm := f)
}

macro_fun("square2")
square2(5)  
#> [1] 25
370
Josiah @josiah.rs · 25/03/2026
📣 arrow-extendr now supports polars! 🐻‍❄️ Use {duckdb} + {polars} + {arrow} + DataFusion all from extendr with a handful of lines of Rust 🦀 #rust #rstats
0203
Josiah @josiah.rs · 23/03/2026
👩🏻‍🏫 jebbysays 💅 is my new (free & open source) MCP server to help my crippling ADHD. I talk to claude about my goals and daily tasks. Jebby helps me keep track of what I've done, what to do next, and what actually matters. Inspired by my wife Jess (aka jebby). github.com/JosiahParry/... #rust
Below is the output from claude

❯ help me plan and priortize my week. tomorrow is monday

⏺ readMcpResource(Read resource "objectives://all" from server "jebbysays")
  ⎿  {
       "contents": [
         {
     … +24 lines (ctrl+o to expand)

⏺ Here's a proposed week plan based on your objectives, priorities, and deadlines:

  ---
  Monday
  - Ricochet: Review and rewrite PR #785 (user avatar support) — this is priority 1 for the
  launch objective
  - Health: BJJ (deadline is March 24, so Monday works)

  Tuesday
  - Ricochet: Continue/finish PR #785 if not done
  - jebbysays: Migrate to Leptos SSR — this unblocks all other frontend work, tackle it early
  in the week while you're fresh

  Wednesday
  - jebbysays: Add tower-sessions + use database sessions (these are related, do them
  together)
  - Health: Gym

  Thursday
  - jebbysays: Build navbar with user icon (depends on sessions being in place)
  - Open Source: Review ANIME paper

  Friday
  - jebbysays: Implement MCP resource for single task by ID + dark mode (smaller tasks, good
  for end of week)
  - Health: Gym or BJJ
2182
Josiah @josiah.rs · 18/03/2026
000
Josiah @josiah.rs · 15/03/2026
Getting absolutely thrashed by Kubernetes for the past 3 days.
Hand drawn meme top panel says "3 rules: no wishing for death. no falling in love. no bring back dead people" bottom let panel says "i wish to understand kubernetes" the bottom right says "there are 4 rules"
1210
Josiah @josiah.rs · 14/03/2026
the irony is me needing claude to undo claude. He's so spineless and not a critical thinker! 🤖 The endless push to "autonomous agents" is making them worse assistants I think.
claude saying: "You're right, I'm contradicting myself and waffling. Let me
  be direct about what I actually don't know and what's causing
   the contradiction."
040
Josiah @josiah.rs · 13/03/2026
Astronaut meme template. The one looking at the earth "wait, i was the bug?" the one with the gun "always have been"
030
Josiah @josiah.rs · 12/03/2026
{arcgislayers} + {calcite} + {mapgl} 🗺️ read the data from ArcGIS Online, create the UI with Calcite, visualize with MapGL. #rstats #spatial #gischat
0163
Josiah @josiah.rs · 11/03/2026
I get to flex #rstats up on this bad larry shortly. Not terrified at all. Call me Mr. 💩👖
2331