Class: Formula

Inherits:
Object
  • Object
show all
Defined in:
lib/formulas/formula.rb

Instance Method Summary collapse

Instance Method Details

#nameObject


26
27
28
# File 'lib/formulas/formula.rb', line 26

def name
  'Generic'
end

#score(text, stats) ⇒ Object

text will be a Hash like so: data =

'raw' => String,
'words' => Array,
'sentences' => Array,
'syllables' => Array

stats will be a Hash like so:

'string_length' => Fixnum,
'letter_count' => Fixnum,
'syllable_count' => Fixnum,
'word_count' => Fixnum,
'sentence_count' => Fixnum,
'average_words_per_sentence' => Float,
'average_syllables_per_word' => Float


22
23
24
# File 'lib/formulas/formula.rb', line 22

def score(text, stats)
  0
end