Class: Rserve::REXP::Function
- Inherits:
-
Rserve::REXP
- Object
- Rserve::REXP
- Rserve::REXP::Function
- Defined in:
- lib/rserve/rexp/function.rb
Overview
represents a Function in R
Constant Summary
Constants inherited from Rserve::REXP
Instance Attribute Summary collapse
-
#body ⇒ Object
Returns the value of attribute body.
-
#head ⇒ Object
Returns the value of attribute head.
Attributes inherited from Rserve::REXP
Instance Method Summary collapse
-
#initialize(head, body) ⇒ Function
constructor
A new instance of Function.
- #to_ruby ⇒ Object
Methods inherited from Rserve::REXP
#as_bytes, #as_double, #as_double_matrix, #as_doubles, #as_factor, #as_float, #as_floats, #as_integer, #as_integers, #as_list, #as_matrix, #as_nested_array, #as_string, #as_strings, #complex?, create_data_frame, #dim, #environment?, #expression?, #factor?, #get_attribute, #has_attribute?, #inherits?, #integer?, #language?, #length, #list?, #logical?, #na?, #null?, #numeric?, #pair_list?, #raw?, #recursive?, #reference?, #split_array, #string?, #symbol?, #to_debug_string, #to_f, #to_i, #to_ruby_internal, #vector?
Constructor Details
#initialize(head, body) ⇒ Function
Returns a new instance of Function.
6 7 8 9 10 |
# File 'lib/rserve/rexp/function.rb', line 6 def initialize(head,body) super() @head=head @body=body end |
Instance Attribute Details
#body ⇒ Object
Returns the value of attribute body.
5 6 7 |
# File 'lib/rserve/rexp/function.rb', line 5 def body @body end |
#head ⇒ Object
Returns the value of attribute head.
5 6 7 |
# File 'lib/rserve/rexp/function.rb', line 5 def head @head end |
Instance Method Details
#to_ruby ⇒ Object
11 12 13 |
# File 'lib/rserve/rexp/function.rb', line 11 def to_ruby {:head=>@head.to_ruby,:body=>@body.to_ruby} end |