Class: RMMSeg::LSDMFOCWRule
- Inherits:
-
Object
- Object
- RMMSeg::LSDMFOCWRule
- Defined in:
- lib/rmmseg/lsdmfocw_rule.rb
Overview
Largest sum of degree of morphemic freedom of one-character words rule.
Instance Method Summary collapse
Instance Method Details
#filter(chunks) ⇒ Object
7 8 9 10 11 12 13 |
# File 'lib/rmmseg/lsdmfocw_rule.rb', line 7 def filter(chunks) chunks.sort { |a, b| b.degree_of_morphemic_freedom <=> a.degree_of_morphemic_freedom }.similar_elements { |a, b| a.degree_of_morphemic_freedom == b.degree_of_morphemic_freedom } end |