Sha256: 4e1eba9109d376ca7a2bfe241d9802e10a049a067db64288d3bfb9acac0e4410

Contents?: true

Size: 1.34 KB

Versions: 6

Compression:

Stored size: 1.34 KB

Contents

# two grapsh
Shoes.app width: 800, height: 500 do
  @values1 = [24, 22, 10, 13, 20, 8, 22]
  @x_axis1 = ['a','b','c','d','e','f', 'g']
  
  @x_axis2 = ['a','b',nil,'d','e','f', 'g']
  #@values2 = [200, 150, 75, 125, 75, 50, 125]
  @values2 = [200, 150, 75, 125, nil, 50, 125]
  stack do
    para "Plot Widget Demo 2"
    flow do 
      button "quit" do Shoes.quit end
    end
    widget_width = 400
    widget_height = 300
    stack do
      flow do
        #para "This is mine!"
        @grf = plot widget_width, widget_height, title: "My Graph", caption: 
          "Look at that! Booyah!!" , font: "Helvetica", auto_grid: true,
          default: "skip"
         @grf2 = plot widget_width, widget_height+100, title: "2nd Graph", caption: 
          "Amazing!!" , font: "Helvetica", auto_grid: false, chart: "line",
          default: "skip", background: cornsilk
      
      end
    end
    cs1 = chart_series values: @values1, labels: @x_axis1,
       name: "foobar", min: 6, max: 26 , desc: "foobar Yy", color: dodgerblue,
       points: true
    @grf.add cs1
    #@grf.add values: @values1, labels: @x_axis1,
    #   name: "foobar", min: 6, max: 26 , desc: "foobar Yy", color: dodgerblue,
    #   points: true
    @grf2.add values: @values2, labels: @x_axis2,
       name: "Bar", min: 50, max:  250, desc: "BarBaz", color: dodgerblue,
       points: true
  end
end

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
scarpe-0.4.0 examples/legacy/not_checked/shoes3-tests/plot/gr2.rb
scarpe-0.3.0 examples/legacy/not_checked/shoes3-tests/plot/gr2.rb
scarpe-0.2.2 examples/legacy/not_checked/shoes3-tests/plot/gr2.rb
lacci-0.2.1 examples/legacy/not_checked/shoes3-tests/plot/gr2.rb
scarpe-0.2.1 examples/legacy/not_checked/shoes3-tests/plot/gr2.rb
scarpe-0.2.0 examples/legacy/not_checked/shoes3-tests/plot/gr2.rb