Class: DBSCAN::Point
- Inherits:
-
Object
- Object
- DBSCAN::Point
- Defined in:
- lib/gtfs_stops_clustering/dbscan.rb
Overview
Point class
Instance Attribute Summary collapse
-
#cluster ⇒ Object
Returns the value of attribute cluster.
-
#cluster_name ⇒ Object
Returns the value of attribute cluster_name.
-
#cluster_pos ⇒ Object
Returns the value of attribute cluster_pos.
-
#items ⇒ Object
Returns the value of attribute items.
-
#label ⇒ Object
Returns the value of attribute label.
-
#visited ⇒ Object
Returns the value of attribute visited.
Instance Method Summary collapse
-
#initialize(point, label) ⇒ Point
constructor
A new instance of Point.
Constructor Details
#initialize(point, label) ⇒ Point
Returns a new instance of Point.
140 141 142 143 144 145 146 147 148 149 150 |
# File 'lib/gtfs_stops_clustering/dbscan.rb', line 140 def initialize(point, label) @items, @cluster, @visited, @label = point, nil, false, label, @cluster_name, @cluster_pos = [] end |
Instance Attribute Details
#cluster ⇒ Object
Returns the value of attribute cluster.
136 137 138 |
# File 'lib/gtfs_stops_clustering/dbscan.rb', line 136 def cluster @cluster end |
#cluster_name ⇒ Object
Returns the value of attribute cluster_name.
136 137 138 |
# File 'lib/gtfs_stops_clustering/dbscan.rb', line 136 def cluster_name @cluster_name end |
#cluster_pos ⇒ Object
Returns the value of attribute cluster_pos.
136 137 138 |
# File 'lib/gtfs_stops_clustering/dbscan.rb', line 136 def cluster_pos @cluster_pos end |
#items ⇒ Object
Returns the value of attribute items.
136 137 138 |
# File 'lib/gtfs_stops_clustering/dbscan.rb', line 136 def items @items end |
#label ⇒ Object
Returns the value of attribute label.
136 137 138 |
# File 'lib/gtfs_stops_clustering/dbscan.rb', line 136 def label @label end |
#visited ⇒ Object
Returns the value of attribute visited.
136 137 138 |
# File 'lib/gtfs_stops_clustering/dbscan.rb', line 136 def visited @visited end |