Class: Numeric
- Defined in:
- lib/rust/core/types/datatype.rb,
lib/rust/stats/probabilities.rb
Instance Method Summary collapse
-
#_rust_prob_distance(other) ⇒ Object
Computes the distance between this and another number.
- #to_R ⇒ Object
Instance Method Details
#_rust_prob_distance(other) ⇒ Object
Computes the distance between this and another number.
8 9 10 11 12 |
# File 'lib/rust/stats/probabilities.rb', line 8 def _rust_prob_distance(other) raise TypeError, "no implicit conversion of #{other.class} into Numeric" unless other.is_a? Numeric return (self - other).abs end |
#to_R ⇒ Object
154 155 156 |
# File 'lib/rust/core/types/datatype.rb', line 154 def to_R self.inspect end |