Sha256: f70e727f09c0473d224d0f70a37847550d6d9bd486c20ef9e988ba23f8ce6d9d

Contents?: true

Size: 927 Bytes

Versions: 296

Compression:

Stored size: 927 Bytes

Contents

require File.join(File.expand_path(File.dirname(__FILE__)), '../../..', 'test_helper.rb')
require 'rbbt/util/R'
require 'rbbt/util/R/plot'

class TestRPlot < Test::Unit::TestCase
  def __test_ggplotgif

    Log.severity = 0
    x = R.eval_a 'rnorm(100, 0, 1)'
    data = TSV.setup(x, "Num~#:type=:single#:cast=:to_f")

    data.add_field "Val" do |k,v|
      k
    end

    R::GIF.eog(data, (0..10).to_a.collect{|i| 100.0 / 10**i}, <<-EOF, nil, nil, :delay => 100)
rbbt.require('reshape')
ggplot(data) + geom_density(bw=frame.value, aes(x=Val))
    EOF

  end

  def test_gif

    Log.severity = 0
    x = R.eval_a 'rnorm(100, 0, 1)'
    data = TSV.setup(x, "Num~#:type=:single#:cast=:to_f")

    data.add_field "Val" do |k,v|
      k
    end

    R::GIF.eog_plot(data, (0..10).to_a.collect{|i| 100.0 / 10**i}, <<-EOF, 400, 400, :delay => 10)
rbbt.require('reshape')
plot(density(data$Val, bw=frame.value))
    EOF

  end
end

Version data entries

296 entries across 296 versions & 1 rubygems

Version Path
rbbt-util-5.27.2 test/rbbt/util/R/test_plot.rb
rbbt-util-5.27.1 test/rbbt/util/R/test_plot.rb
rbbt-util-5.27.0 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.171 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.170 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.169 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.168 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.167 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.166 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.164 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.163 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.162 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.161 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.160 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.159 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.158 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.157 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.156 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.155 test/rbbt/util/R/test_plot.rb
rbbt-util-5.26.154 test/rbbt/util/R/test_plot.rb