lib/raingrams/probability_table.rb in raingrams-0.1.1 vs lib/raingrams/probability_table.rb in raingrams-0.1.2

- old
+ new

@@ -139,9 +139,18 @@ @probabilities.clear return self end + # + # Returns a Hash representation of the probability table. + # + def to_hash + build + + return @probabilities + end + def inspect if @dirty "#<ProbabilityTable @total=#{@total} @frequencies=#{@frequencies.inspect}>" else @probabilities.inspect