• Keine Ergebnisse gefunden

5.4 User-Steerable Iterative Matrix Reordering

5.4.3 Interaction with the Matrix in Projected Space

After sketching our idea and the interaction with matrices in the projection space, we now describe the details of our approach.

Projection of Matrix Data Our approach relies on a projection technique to map matrix rows or columns to 2D space for sorting interaction. Kosinov and Caelli considered the task of comparing two graphs with an inexact graph matching approach in [KC02;

CK04]. They showed that appropriately projected matrix vectors reflect the similarity relationships present in the high-dimensional matrix dataindependentof the matrix’s initial ordering. The researchers proposed the use ofeigendecomposition-based projection techniques, because the eigenvalue spectrum of a matrix is invariant with respect to similarity transformations. That is for any non-singular matrixM, the product matrix PMP−1has the same eigenvalues asM. Specifically, this means that the derived spectrum of a graph represented by its adjacency matrix is not affected by row/column permutations P[KC02]. This insight builds the basis of our approach since it allows the perception and manipulation of a matrix’s ordering without having to recompute its projection points.

The task of a projection technique is to reduce the size of a dataset by reducing the number of dimensions while minimizing the information loss. In the case of linear projec-tion techniques, a value is determined for each of the high-dimensional components that represents the dimension’s weight in the low-dimensional projected space. The projection vector is then a linear combination of the original dimensions. In essence, linear projec-tion techniques attempt to separate important from unimportant dimensions to form the projection space. While linear projection techniques are able to preserve linear structures, non-linear projection techniques also take non-linear structures into account. Examples of non-linear structures include arbitrarily shaped clusters or curved shapes. These tech-niques try to preserve the high-dimensionalneighborhoodproperties, such as pairwise distances, in the low-dimensional space. Consequently, non-linear projection techniques seek to separate projection points whenever their high-dimensional counterparts are far apart.

In our implementation, we include an exemplary linear and non-linear projection technique. Specifically,principle component analysis (PCA)[Jol86], andclassical scaling (metric multidimensional scaling)[CC08]. We used the implementations of PCA and Classical Scaling from the “Projection Explorer Framework” of Paulovich [POM07].

Local Group Ordering A local group ordering corresponds to a reordering of a submatrix either with the help of an automated sorting algorithm or a user-steered manual reordering decision. It can only be applied in the matrix representation if all the row-/column vectors in the group are arranged sequentially. If this is not the case, then the linear ordering of the matrix will not be consistent after a row-/ column reordering operation. To establish the selection of a group of vertices we implemented thePartSortalgorithm shown in Algorithm 8. Based on a user selection, it arranges the corresponding matrix elements sequentiallyandensures that the relevant 2D projection vertices are adjacent to one another (i.e. connected by edges).

Algorithm 8The PartSort algorithm prepares the matrix for a local reordering. It arranges the selected vertices sequentially, beginning with the first selection id.

1: procedurePARTSORTALGORITHM

Require: Original ordering of DataVectorList 2: while!SelectionIdList.isEmpty()do 3: Id1 := SelectionIdList.getFirstID() 4: Id2 := SelectionIdList.getSecondID() 5: if!DataVectorList.isNextTo(Id1, Id2)then 6: DataVectorList.insertNextTo(Id1, Id2)

7: end if

8: SelectionIdList.remove(Id1) 9: end while

returnOrdered DataVectors with sequentially connected SelectionIDs 10: end procedure

ThePartSortalgorithm prepares the matrix for a local reordering. After this initial grouping, all available matrix sorting algorithms can be applied on the selected submatrix as if the matrix stands alone. The last step in the local reordering of submatrices is the reassembling of the matrix. Figure 5.5 shows our matrix reassembling schema.

Figure 5.5Matrix reassembling schema after local reordering. The arrows indicate the necessary re-adaption type that has to be applied.

As noted above, a 2D space vertex selection corresponds to a submatrix selection in the matrix image space. For our example case shown in Figure 5.5, the user selection

Figure 5.6The Sorting Interaction Framework allows the assessment of the performance of matrix sorting algorithms and enables users to steer the sorting process interactively. The framework is used to visualize matrices and their projections. Here, an 180×180 matrix is rendered using two ordering algorithms. The performance of the two algorithms varies highly in terms of their linear arrangement (sorting quality criterion). The matrix’s projection space allows to the visual analysis of sorting improvement potential. A set of simple interactions in the projection space lets user steer and understand the automatic sorting algorithms.

corresponds to the submatrix 5. After reordering this submatrix, the horizontal and vertical axis reordering differences have to be applied to all other submatrices, too.

While the submatrix 1 remains untouched by the local sorting (no change of the row/-column ordering), all other submatrices have to be adapted. Depending on a submatrix’s position relative to submatrix 5 either a horizontal (column-wise) or vertical (row-wise) or horizontal and vertical adaptation has to be applied. For example, submatrices 2 and 3 will only be affected in the horizontal direction. The same applies for submatrices 4 and 7 in vertical direction. Therefore, a column-/row swapping helps to reassemble the matrices correctly. Adaptations to submatrices 6, 8 and 9 must be applied in both the horizontal and vertical directions.

Reordering Strategies A formally correct linear arrangement is present in the projection view if the graph is connected and there exists exactly one acyclic path that connects all vertices. Accordingly, every user intervention/manual adaption of the path inevitably

requires reestablishing this formal requirement. As an example, edge insertions introduce cycles, which make the linear arrangement ambiguous by introducing two potential paths.

Generally, we can categorize edge set manipulations into two modification types:

1. Forward Edge Modifications:Forward edges are those edges whose linear arrange-ment start index (index of the inserted edge’s outgoing vertex) is smaller than the end index (index of the inserted edge’s incoming vertex). For example, if the user wants to place the 1st row-/column vector next to the 5t hrow-/column vector.

2. Backward Edge Modifications:Backward edges are those edges whose start index is larger than the end index. For example, if the user wants to place the 5t h row-/column vector next to the 1st row-/column vector.

For both edge modification types, different reordering strategies have to be applied, which ultimately have a significant impact on the overall sorting quality with respect to the linear arrangement. In general, reestablishing a correct linear arrangement is achieved by inserting so-called“reconstruction edges”to build one acyclic path that connects all vertices.

As a proof of concept and a point of further research we implemented two different reordering strategies, which will be described in the following.

Figure 5.7Two matrix reordering strategies are possible: A forward edge modification (upper diagram) and a backward edge modification (lower diagram). Depending on the type of reordering strategy, different approaches to reestablish a formally correct linear arrangement have to be applied.

As the upper part of Figure 5.7 depicts, one implementation of the forward edge modification algorithmis to split the vertex set into three disjunct subsets. The first subset contains all vertices with an index before the insertion edge’s starting point (V2) in the Set1=[V0,V1]. The second subset contains all edges with an index larger than the starting point and smaller than the endpoint (V8) in theSet2=[V3,V4,V5,V6,V7]. Finally, the third subset contains all edges with an index after the endpoint in theSet3=[V9,V10].

The new vertex sequence is calculated as follows: First, we start the linear arrangement by retaining the vertices from theSet1=[V0,V1] and then add insertion edge’s start point and end point [V0,V1,V2,V8]. ThenSet3is concatenated [V0,V1,V2,V8,V9,V10]. Finally, a newreconstruction edgeis added to append all items inSet2, leading to the final linear arrangement of [V0,V1,V2,V8,V9,V10,V3,V4,V5,V6,V7].

As the lower part in Figure 5.7 depicts thebackward edge modification algorithmis slightly more complicated. We also split the vertex set into three subsets. In this case Set1contains all vertices after the insertion edge’s endpointSet1=[V3,V4,V5,V6,V7]. In the second setSet2we collect the ordering from the initial linear ordering start until the insertion edge’s endpointSet2=[V0,V1]. Finally, we store all vertices after the insertion edge’s start point inSet3=[V9,V10]. The new linear arrangement starts with the insertion edge sequence [V8,V2]. ThenSet1is attached [V8,V2,V3,V4,V5,V6,V7] and a reconstruc-tion edge needs to be appended to connect toSet2; [V8,V2,V3,V4,V5,V6,V7,V0,V1]. Finally, another reconstruction edge connects to the missing vertices inSet3and finalizes the linear arrangement to [V8,V2,V3,V4,V5,V6,V7,V0,V1,V9,V10].

A wide range of other implementations for the edge modifications are possible. While the algorithms presented above are just one heuristic, they perform well in establishing a better linear arrangement in our experiments. However, more sophisticated algorithms that minimize the reconstruction edges’ length while retaining most of the input linear ordering are imaginable. These algorithms need to judge whether the user should be overruled for the sake of a better linear arrangement. Since these research questions relate to uncertainty (visualizations) and fuzzy decisions they were not investigated in this paper.