I don't know who needs to hear this but in R on Mac or Linux:
> readLines(pipe('echo "1,2,3" | awk -F "," \'{print $2}\''))
[1] "2"
#RStats
2
1
1
1
I show that trick in STAT 447 (which got a lecture on sed and awk added this year) and have a few StackOverflow answer showing that 'pattern', here is one:
stackoverflow.com/a/23198223…
So #rstats gets better with #awk too :)
Oct 20, 2021 · 5:18 PM UTC
2
1

