Skip to content

Commit

Permalink
method fix, remove for delete
Browse files Browse the repository at this point in the history
  • Loading branch information
Esteban Pastorino committed Jan 24, 2011
1 parent 0a21102 commit dfa213b
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions lib/classifier/lsi.rb
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ def categories_for(item)
#
def remove_item( item )
if @items.keys.index item
@items.remove item
@items.delete item
@version += 1
end
end
Expand Down Expand Up @@ -297,7 +297,7 @@ def highest_ranked_stems( doc, count=3 )

def marshal_dump
[ @auto_rebuild, @word_list, @items, @version, @built_at_version,
@options,
@options
]
end

Expand All @@ -306,6 +306,10 @@ def marshal_load(data)
@options = data
end

def to_yaml_properties
%w{ @auto_rebuild @word_list @items @version @built_at_version @options }
end

private
def build_reduced_matrix( matrix, cutoff=0.75 )
# TODO: Check that M>=N on these dimensions! Transpose helps assure this
Expand Down

0 comments on commit dfa213b

Please sign in to comment.