File: 3d_surface_plot.rb

package info (click to toggle)
ruby-gnuplot 2.6.2-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 204 kB
  • ctags: 52
  • sloc: ruby: 456; makefile: 2
file content (14 lines) | stat: -rw-r--r-- 218 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
require "gnuplot"

Gnuplot.open do |gp|
  Gnuplot::SPlot.new( gp ) do |plot|
    plot.grid

    plot.data = [
      Gnuplot::DataSet.new( "x**2+y**2" ) do |ds|
    	ds.with = "pm3d"
      end
    ]
  end
  sleep 10
end