New course! Every coder should learn Generative AI!
Try a free lesson+ 1
Help me debug the following program in ruby
The program below is expected to display a simple graph using gnuplot gem but don't know why it's giving runtime error . Help me fix it . https://code.sololearn.com/cZ0bCe99Kwta/?ref=app
3 Answers
+ 2
Does your program work on your own computer?
Read your runtime error. The gnuplot executable is not found.
gnuplot is a linux utility that must be installed separately.
http://www.gnuplot.info/
The ruby gem 'gnuplot' is only a wrapper for this, it depends on the existence of pre-installed gnuplot.
You can see installation instructions here:
https://github.com/rdp/ruby_gnuplot/tree/master
I think this is not going to work on Sololearn.
+ 2
Oh ok it's funny and crazy to expect sl for such things 🤭😆😅
+ 1
Your code not getting the path of installed gem it will work on your system . If u wana test in phone u can try with heroku connect your GitHub with heroku