Forum: Ruby Re: Calling plotutils from xemacs using Ruby GSL

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
unknown (Guest)
on 2006-03-12 15:41
(Received via mailing list)
Sorry, I actually wanted to say something else in my last mail,
letting you try

> ruby rnd3.rb | graph -Tps > ,

which works out for me. It sends the results from ruby to the  external
GNU program "graph" , which is part of the plotutils package.
I can then open the file with ghostscript (gv,ggv or whatever).

The errors

NameError: uninitialized constant RND etc..

you reported come from the fact that Ruby does not know what these
are, and after some digging into the description of rb-gsl, I found
out that there are two ways of requiring rb-gsl,

require "rbgsl" or require "gsl",

one of these forms lets you drop everything before the '::' , so you


instead of

a = RND::dir_2d(r) .

Maybe the author changed his mind on which form of require to  associate
with which form in between...

But I still am not able to run the first program you posted, either,
where I also get the error

graph([x,y], [roots.real,zero], "-T X -C -g 3 -S 4")
NoMethodError: GNU  plotutils required
from (irb):7:in `graph'
from (irb):7

you reported. I do not know how to fix this directly, but for  me,  it
out to patch that by piping the results of a ruby program into graph  as

Sorry I can't help any further -maybe more experienced users of
with plotutils under rb-gsl are willing to help out ?

Best regards,

This topic is locked and can not be replied to.