Class: ModelFox::BagOfWordsCosineSimilarityFeatureContribution
- Inherits:
-
Object
- Object
- ModelFox::BagOfWordsCosineSimilarityFeatureContribution
- Defined in:
- lib/modelfox/modelfox.rb
Overview
This describes the contribution of a feature from a bag of words cosine similarity feature group.
Instance Attribute Summary collapse
-
#column_name_a ⇒ Object
readonly
This is the name of the source column a for the feature group.
-
#column_name_b ⇒ Object
readonly
This is the name of the source column b for the feature group.
-
#feature_contribution_value ⇒ Object
readonly
This is the amount that the feature contributed to the output.
-
#feature_value ⇒ Object
readonly
This is the value of the feature.
Instance Method Summary collapse
-
#initialize(column_name_a:, column_name_b:, feature_contribution_value:, feature_value:) ⇒ BagOfWordsCosineSimilarityFeatureContribution
constructor
A new instance of BagOfWordsCosineSimilarityFeatureContribution.
Constructor Details
#initialize(column_name_a:, column_name_b:, feature_contribution_value:, feature_value:) ⇒ BagOfWordsCosineSimilarityFeatureContribution
Returns a new instance of BagOfWordsCosineSimilarityFeatureContribution.
200 201 202 203 204 205 |
# File 'lib/modelfox/modelfox.rb', line 200 def initialize(column_name_a:, column_name_b:, feature_contribution_value:, feature_value:) @column_name_a = column_name_a @column_name_b = column_name_b @feature_contribution_value = feature_contribution_value @feature_value = feature_value end |
Instance Attribute Details
#column_name_a ⇒ Object (readonly)
This is the name of the source column a for the feature group.
193 194 195 |
# File 'lib/modelfox/modelfox.rb', line 193 def column_name_a @column_name_a end |
#column_name_b ⇒ Object (readonly)
This is the name of the source column b for the feature group.
195 196 197 |
# File 'lib/modelfox/modelfox.rb', line 195 def column_name_b @column_name_b end |
#feature_contribution_value ⇒ Object (readonly)
This is the amount that the feature contributed to the output.
199 200 201 |
# File 'lib/modelfox/modelfox.rb', line 199 def feature_contribution_value @feature_contribution_value end |
#feature_value ⇒ Object (readonly)
This is the value of the feature.
197 198 199 |
# File 'lib/modelfox/modelfox.rb', line 197 def feature_value @feature_value end |