31 #include "WDataSetHierarchicalClustering.h"
42 std::map< size_t, WFiberCluster::SPtr > allClusters )
65 return "DataSetHierarchicalClustering";
70 return "A tree of fiber clusters.";
86 std::vector< WTreeNode::SPtr > result;
88 if( node->level() <= level )
90 result.push_back( node );
94 for(
size_t i = 0; i < node->getChildren().size(); i++ )
97 result.reserve( result.size() + c.size() );
98 result.insert( result.end(), c.begin(), c.end() );
static std::shared_ptr< WPrototyped > getPrototype()
Returns a prototype instantiated with the true type of the deriving class.
virtual const std::string getName() const
Gets the name of this prototype.
virtual ~WDataSetHierarchicalClustering()
Destructor.
std::vector< WTreeNode::SPtr > getClustersDownToLevel(WTreeNode::SPtr node, size_t level)
Returns all clusters down (root node has highest level) to a certain level in the hierarchy.
WTreeNode::SPtr m_rootNode
Pointer to the root cluster.
WTreeNode::SPtr getRootNode()
Returns the root cluster.
static std::shared_ptr< WPrototyped > m_prototype
The prototype as singleton.
std::map< size_t, WFiberCluster::SPtr > m_clusters
Stores the cluster map.
WDataSetHierarchicalClustering()
Constructs a new set of tracts.
std::map< size_t, WFiberCluster::SPtr > getClusterMap()
Returns the whole cluster map.
virtual const std::string getDescription() const
Gets the description for this prototype.
std::shared_ptr< WTreeNode > SPtr
Shared pointer abbreviation.