Corey Sparks
banner
coreysparks1.bsky.social
Corey Sparks
@coreysparks1.bsky.social
Demographer, Research Scientist at The Coleridge Initiative, reformed #academic #rstats
https://coreysparks.github.io/appdem_Book/
I was just excited that somebody responded. after the heyday of Twitter a few years ago, where this type of thing happened every single day I was worried that the community wasn’t really around anymore.
September 6, 2025 at 1:00 PM
I typically enjoy a janky solution but this is for a project where I'm trying to teach new R users, so may not this time
September 6, 2025 at 12:58 PM
The purpose is to show the r for the inline expression
September 5, 2025 at 10:54 PM
ah, duh, i'd put it in a chunk, that works too!
September 5, 2025 at 5:20 PM
that does it!
September 5, 2025 at 5:16 PM
this puts the vector notation in front of the output, and adds an extra r in there

knitr::inline_expr('r mean(1:10)', "md")
September 5, 2025 at 5:14 PM
🤢
September 5, 2025 at 5:08 PM
even better!
September 5, 2025 at 5:07 PM
hideous, but beautiful too?
ytb @ivelasq3.bsky.social
September 5, 2025 at 5:04 PM
yup, I get
September 5, 2025 at 4:50 PM
September 5, 2025 at 4:47 PM
that prints 5.5 in the report
September 5, 2025 at 4:46 PM
That did it, thanks @ercbk.bsky.social
``{r} mean(1:10) ``
gave me
September 5, 2025 at 4:44 PM
Close! if I use
`{{r}} r mean(1:10)`

I get this:
{r} r mean(1:10)

but what I want is

r mean(1:10)
September 5, 2025 at 4:35 PM
NOT just be
5.5
September 5, 2025 at 4:26 PM
I'm listening to this episode and would highly recommend it to those who've never thought about count variable models, BUT!! Where's the denominator?? I'm seriously jonesing for a discussion of offsets in these models, and yes it's because I'm a #demographer coreysparks.github.io/appdem_Book/...
Applied Demographic Data Analysis - 4  Macrodemographic Analysis of Places
coreysparks.github.io
April 15, 2025 at 12:38 PM
The whatever is the fun part
March 28, 2025 at 10:01 PM