Class: Tangram::NormalizedFeatureContribution

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

Overview

This describes the contribution of a feature from a normalized feature group.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(column_name:, feature_value:, feature_contribution_value:) ⇒ NormalizedFeatureContribution

Returns a new instance of NormalizedFeatureContribution.


126
127
128
129
130
# File 'lib/tangram/tangram.rb', line 126

def initialize(column_name:, feature_value:, feature_contribution_value:)
  @column_name = column_name
  @feature_value = feature_value
  @feature_contribution_value = feature_contribution_value
end

Instance Attribute Details

#column_nameObject (readonly)

This is the name of the source column for the feature group.


121
122
123
# File 'lib/tangram/tangram.rb', line 121

def column_name
  @column_name
end

#feature_contribution_valueObject (readonly)

This is the amount that the feature contributed to the output.


125
126
127
# File 'lib/tangram/tangram.rb', line 125

def feature_contribution_value
  @feature_contribution_value
end

#feature_valueObject (readonly)

This is the value of the feature.


123
124
125
# File 'lib/tangram/tangram.rb', line 123

def feature_value
  @feature_value
end