Project

sum_sum

0.0
No commit activity in last 3 years
No release in over 3 years
SumSum allows you to generate simple reports on the count of values in hashes.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 1.0.3
>= 0.1.9
>= 0.3.9
>= 2.4.0
 Project Readme

SumSum

SumSum allows you to generate simple reports on the count of values in hashes.

Installation

gem install sum_sum

Basic Usage

sum_sum = SumSum.new(:type, :name, :version)

sum_sum.add(:type => :Browser, :name => :Firefox, :version => "3.6.13")
sum_sum.add(:type => :Browser, :name => :Safari, :version => "5.0.3")
sum_sum.add(:type => :Browser, :name => :Firefox, :version => "3.6.12")
sum_sum.add(:type => :Browser, :name => :Chrome, :version => "5.0")

sum[:Browser].count
=> 4
sum[:Browser].keys
=> [:Firefox, :Safari, :Chrome]
sum[:Browser][:Firefox].count
=> 2
sum[:Browser][:Firefox].share
=> 0.5
sum[:Browser][:Firefox]["3.6.13"].share
=> 0.5

BlaBla

Copyright (c) <%= Date.today.year %> Yolk Sebastian Munz & Julia Soergel GbR

Beyond that, the implementation is licensed under the MIT License.