Talk Suggestion - Ruby R and Ruby command-line

0 views
Skip to first unread message

Techbelly

unread,
Sep 16, 2008, 2:38:31 PM9/16/08
to Ruby Manor
I have two talk suggestions, the first more appropriate for an 8
minute slot and the second for 30 minutes.

1. Ruby simple text processing on the command line (eg. on log files)
• using -p, -n and -e flags to the ruby interpreter
• one liners that are easier for mortals to grok than the
equivalent grep, sed, awk and tr
• some tips and tricks that'll make you look good and clever

2. Using R with ruby for statistical programming
• doing some proper statistics with error bars and everything
using a mixture of R and ruby.

One caveat - the wife is expecting child around the time of the Manor,
so I may need someone to stand in for me; or maybe a partner that
wants to develop the talks with me.

Ben

Roland Swingler

unread,
Sep 16, 2008, 4:56:12 PM9/16/08
to Ruby Manor
Hi,

I thought about doing a talk like 1. but wasn't sure if it was right
for ruby manor - I was thinking of proposing it as a lightning talk
whenever we did those next at lrug. The problem with is that although
there are are a surprisingly large number of cool things you can do
passing command line flags to ruby (which not many people know about
afaik), it is quite easy to find out that sort of stuff by just
reading the pickaxe for ten minutes. I don't think I'd learn much from
it, but others may be interested.

I'd be interested in 2. - R is a language that I've never got round to
looking at because it is too far off the beaten track - and I probably
never will until someone tells me something about it.

Cheers,
Roland

Pratik

unread,
Sep 16, 2008, 4:58:08 PM9/16/08
to ruby-...@googlegroups.com
I like the second one too - Using R with ruby for statistical programming
--
Cheers!
- Pratik
http://m.onkey.org

James Adam

unread,
Sep 16, 2008, 5:15:55 PM9/16/08
to ruby-...@googlegroups.com
I like both of these ideas!

On 16 Sep 2008, at 19:38, Techbelly wrote:

>
> I have two talk suggestions, the first more appropriate for an 8
> minute slot and the second for 30 minutes.
>
> 1. Ruby simple text processing on the command line (eg. on log files)
> • using -p, -n and -e flags to the ruby interpreter
> • one liners that are easier for mortals to grok than the
> equivalent grep, sed, awk and tr
> • some tips and tricks that'll make you look good and clever

Sounds like a good quick talk. Do you have some practical examples in
mind? Presumably stuff like getting information out of log files?

>
> 2. Using R with ruby for statistical programming
> • doing some proper statistics with error bars and everything
> using a mixture of R and ruby.

This is intriguing. What sort of statistics have you been performing?
Do you have any examples in mind?

James

Ben Griffiths

unread,
Sep 17, 2008, 6:55:23 PM9/17/08
to ruby-...@googlegroups.com
James,

I like the way you're implying I might have some iceberg-like plan of
which my previous email was the tip. Keep it up.

I'll try and come up with some better examples than the log-file ones,
although that's probably the most common use I've found. How about
what to do if you come across one of those government data discs that
they keep losing? If anyone could supply an actual disk that would be
good otherwise I'll get one from ebay like all the other crims.

In terms of R - I've used it to analyse and visualise all kinds of
things but I think it's most interesting in how you attach ruby to it
- you can call it from ruby, call ruby programs from it or ...
translate R to ruby somehow.

I found it pretty hard to get started with it, much of the web stuff
written about R is google-invisible. But it's a really rich seam. My
talk won't be about statistics, because I'd be willing to guess that
anyone from the audience would know more than I do.

Here's a taste of how R works with Python: Rpy
(http://rpy.sourceforge.net/rpy_demo.html) And I'd like to approach
connecting Ruby and R in that way as an idea at the Manor - there have
been a few attempts but none have borne fruit AFAIK. The endpoint is
that R can become a very good statistical library in ruby, and not
just a scary stats thing.

Ben

James Adam

unread,
Sep 18, 2008, 11:15:34 AM9/18/08
to ruby-...@googlegroups.com
On 17 Sep 2008, at 23:55, Ben Griffiths wrote:

>
> James,
>
> I like the way you're implying I might have some iceberg-like plan of
> which my previous email was the tip. Keep it up.

Will do :)


> I'll try and come up with some better examples than the log-file ones,
> although that's probably the most common use I've found. How about
> what to do if you come across one of those government data discs that
> they keep losing? If anyone could supply an actual disk that would be
> good otherwise I'll get one from ebay like all the other crims.

I think that log file examples are fine - I didn't mean to give the
impression that I didn't. My command-line grep/sed/awk-fu is as weak
as could be.


> In terms of R - I've used it to analyse and visualise all kinds of
> things but I think it's most interesting in how you attach ruby to it
> - you can call it from ruby, call ruby programs from it or ...
> translate R to ruby somehow.
>
> I found it pretty hard to get started with it, much of the web stuff
> written about R is google-invisible. But it's a really rich seam. My
> talk won't be about statistics, because I'd be willing to guess that
> anyone from the audience would know more than I do.
>
> Here's a taste of how R works with Python: Rpy
> (http://rpy.sourceforge.net/rpy_demo.html) And I'd like to approach
> connecting Ruby and R in that way as an idea at the Manor - there have
> been a few attempts but none have borne fruit AFAIK. The endpoint is
> that R can become a very good statistical library in ruby, and not
> just a scary stats thing.

For me, stats are indeed scary. But I think if you can find an example
that's compelling, this would make a very interesting topic.

Cheers,

James

Chris Lowis

unread,
Sep 18, 2008, 3:59:04 PM9/18/08
to Ruby Manor
> Here's a taste of how R works with Python: Rpy
> (http://rpy.sourceforge.net/rpy_demo.html) And I'd like to approach
> connecting Ruby and R in that way as an idea at the Manor - there have
> been a few attempts but none have borne fruit AFAIK.  The endpoint is
> that R can become a very good statistical library in ruby, and not
> just a scary stats thing.

Beat me to the punch, I was going to suggest a similar talk myself !
Possibly comparing and contrasting the "scientific" aspects of R with
those available by binding to GSL (Gnu Scientific Library). Anyway,
count me among the interested. You might find these R bindings
useful :
http://rubyforge.org/projects/rsruby/ - in the past they've seemed to
work well for me.

I'm Interested to hear how this one develops,

Chris

petef

unread,
Sep 19, 2008, 11:33:16 AM9/19/08
to Ruby Manor
> 1. Ruby simple text processing on the command line (eg. on log files)

+1

> 2. Using R with ruby for statistical programming

+1

mnemonaut

unread,
Sep 24, 2008, 5:27:38 AM9/24/08
to Ruby Manor
On Sep 16, 7:38 pm, Techbelly <bengriffi...@gmail.com> wrote:

> 2. Using R with ruby for statistical programming

+1

Paul Battley

unread,
Sep 24, 2008, 7:38:15 AM9/24/08
to Ruby Manor
+1 for R

I've used R a bit before, but never enough to internalise the syntax.
I have to RTFM every time. Can Ruby help me here?

Paul.

James Adam

unread,
Sep 25, 2008, 8:55:49 AM9/25/08
to ruby-...@googlegroups.com
That's a good seam of talk-gold that Paul has touched on. I'm sure
there must be other libraries with difficult syntax that Ruby has (or
can) wrap into loveliness...

Rob McKinnon

unread,
Oct 23, 2008, 1:19:18 PM10/23/08
to ruby-...@googlegroups.com
> 1. Ruby simple text processing on the command line (eg. on log files)

+1 - my command line is stuck in the land of grep, sed and xargs, be
good to be reminded of Ruby alternatives, particularly useful would be
the incantation for "replace all occurrences of this with that in
these files"

> 2. Using R with ruby for statistical programming

+1 - played with R recently in its native syntax, bit of a nightmare
if you can't find an exact example already pasted online. Does running
from irb might make inspecting results easier?

Rob

2008/9/24 Paul Battley <pbat...@gmail.com>:

Reply all
Reply to author
Forward
0 new messages