A Polyline-Based Visualization Technique for Tagged Time-Varying Data
Sayaka Yagi, Yumiko Uchida, Takayuki ItohOchanomizu University{sayaka, yumi-ko, itot}@itolab.is.ocha.ac.jp
Abstract
We have various interesting time-varying data in ourdaily life, such as weather data (e.g., temperature and airpressure) and stock prices. Such time-varying data is often
associated with other information: for example, temperatures can be associated with weather, and stock prices canbe associated with social or economic incidents. Meanwhile, we often draw large-scale time-varying data by multiple polylines in one space to compare the time variationof multiple values. We think it should be interesting if suchtime-varying data is effectively visualized with their associated information. This paper presents a technique forpolyline-based visualization and level-of-detail control oftagged time-varying data. Supposing the associated information is attached as tags of the time-varying values,
the technique generates clusters of the time-varying values grouped by the tags, and selects representative values
for each cluster, as a preprocessing. The technique thendraws the representative values as polylines. It also provides a user interface so that users can interactively selectinteresting representatives, and explore the values which
belong to the clusters of the representatives.
Keywords— Information visualization,
varying data, level-of-detail control.

tagged time-1 Introduction
We represent time-varying data as polyline charts veryoften. Also, we commonly draw multiple time-varying
values in a single polyline chart space so that users cancompare the time-varying values. On the other hand,
we often deal with hundreds or even thousands of timevarying values in the above mentioned various fields. It
is usually difficult to read if we draw hundreds or thousands of polylines in a single space. Several recent works
have addressed the visualization of such large-scale timevarying data. Wattenberg et al. presented a sketch-based
query interface to search for specific shapes of polylines[8]. Hochheiser et al. presented Timeboxes and TimeSearcher [3], a gradient- and range-based query interface
for polyline-based time-varying data visualization Someworks focused on similarity-based pattern and outlier dis-covery. Buono et al. presented a technique to interactively
search for similar pattern [1] as an extension of TimeSearcher, and a similarity-based forecasting technique [2]for the forecasts the future patterns. Lin et al. presented
a technique to discover non-trivial patterns [5], by clustering a set of time-varying values and searching for outliers. Wang et al. presented a technique for important polyline selection [7]. Recently we presented two time-varying
data visualization techniques, featuring sketch query on theclustered view [6], and pattern display on the heatmap [4].
Meanwhile, such time-varying data is often associatedwith other information: for example, temperatures can beassociated with weather, and stock prices can be associated with social or economic incidents. Such information
may be tightly correlated with the time-varying values, andtherefore, it should be useful if time-varying data visualization techniques simultaneously display such associatedinformation.
This paper presents a new time-varying data visualization technique which supposes time series values have tagsfor each time. We suppose that tags consist of a set of predefined terms: for example, sunny, cloudy, and rainy forweather data, or exercising, eating, or sleeping for healthcare data. As a preprocessing, the technique clusters polylines based on their shapes and tags, and then selects representative polylines from the clusters. It realizes smooth
level-of-detail control by interactively controlling the number of polylines to be displayed. Also, the technique features click and sketch interfaces so that users can interactively select particular polylines which are tagged with theuser-interested terms. This paper presents the effectiveness of the presented technique with Japanese weather data
recorded by AMeDAS (Automated Meteorological Data
Acquisition System).

2 Level-of-detail control for time varying
data visualization
This section briefly introduces a level-of-detail control
and sketch interface [6] for time-varying data visualization
previously we presented.
The technique supposes the following time series data,consisting of a set of values P = (p1 , p2 , ..., pn ) repre-

Two values are in the samegroup in this time period.

hbh0v0k time steps.

va(a) Grid covering
the drawing area(b) Quantization ofthe polylines(c) Clipping polylines
in a same group

Figure 1: Quantization of polylines.
sented as n polylines. We describe the values of a polyline
as pi = (pi1 , pi2 , ..., pim ); pij denotes the value at the j-thtime of the i-th polyline. We draw the set of values as apolyline chart, while the horizontal axis denotes the 1st to
the m-th time, and the vertical axis denote the magnitudeof the values.
As a preprocessing, the technique temporarily quantizes
polylines, generates clusters of them, and selects representative polylines from the clusters. While the quantization
step, the technique generates a grid surrounding all polylines, and calculates intersections between the polylinesand grid-lines. It then generates rough polylines by connecting the intersections, and uses them for the clustering.
Number of clusters can be controlled by the resolution of
the grid as well as similarity threshold values, and our implementation prepares several clustering results so that thenumber of representative polylines smoothly varies.
The technique then initially displays representative
polylines. Smoothly switches clustering results, it canseamlessly change the number of representative polylines
to be displayed. Also, the technique provides a click interface, so that users can specify interesting representatives
by directly clicking. It also provides a sketch interface,
so that users can specify interesting representatives whichhave partial shapes similar to the sketched curves.

3 Extension to the tagged time-varying datavisualization
This section proposes an extended visualization technique for tagged time-varying data. This paper extends theaforementioned time series data as follows: we describe
the tags of the i-th polyline as wi = (wi1 , wi2 , ..., wim );wij denotes the tag at the j-th time of the i-th polyline, as
well as pij denotes the value at the j-th time of the i-thpolyline.

3.1 Clustering and Representative Polyline Selection
The extended technique displays adequate number ofrepresentative polylines to reduce the cluttering among thepolylines and improve the readability. The technique clips
the polylines interval by interval, and then generates clusters of clipped polylines for each interval, where clipped
polylines in a cluster is similarly shaped and tagged.
The technique first generates a grid covering the drawing area, and then divides into a × b subspaces, as shown in
Figure 1(a). Here this paper formalizes the grid as follows:
hi is the i-th horizontal line of the grid (0 ≤ i ≤ b), vi isthe i-th vertical line of the grid (0 ≤ i ≤ a), ti is the timeat vi , and bi is the value at hi .
The technique first samples P at t0 to ta , and temporarily quantizes the sampled values at b0 to bb . The techniquethen generates groups of polylines, if the polylines havethe same quantized values both at ti−1 and ti , as shown inFigure 1(b). It then clips polylines of a group by ti−1 andti , as shown in Figure 1(c), and generates clusters of theclipped polygons.
Procedure for clustering of tagged polylines is as follows. Figure 2 denotes the procedure, while the colorsof polylines denote their dominant tags. Here, the technique regards the clipped polylines as k-dimensional vectors, while they contain k time steps between ti−1 and ti .
This step firstly divides the clipped polylines according totags, as shown in Figure 2(b), using a dendrogram from thepolylines constructed according to similarities of their kdimensional vectors (wjti−1 , ..., wjti ). The technique thenapplies a non-hierarchical clustering (e.g. k-means) to thepolylines in each cluster, using their k-dimensional vectors(pjti−1 , ..., pjti ). Consequently, it generates clusters consisting of similarly tagged and shaped fragments of polylines, as shown in Figure 2(c).

(a) Clipped polylines(c) Shape-based clustering(b) Tag-based clustering(d) Representative polylinesFigure 2: Clustering of polylines.
Next, the technique selects representative polylines, foreach cluster, as shown in Figure 2(d). Our current implementation simply extracts a polyline as the representative, which is the closest to the center of a cluster in a kdimensional vector space. This strategy is basically good
because it selects average polylines. Here, if one or morepolylines in a cluster have been already selected as the representative polylines of other clusters, the technique does
not select any new representative from the current cluster,so that we can reduce the total number of representativepolylines.

3.2

Interactive Visualization

The extended technique represents the time-varying
data as colored polylines. It assigns colors to the tags (e.g.
red to sunny, and gray to cloudy, to the tags of weatherdata), and draws the polyline in the assigned colors. If thevertices of a segment of a polyline have different tags, itinterpolates the colors along the segments. The techniquealso features selective polyline display based on the tags.
Users can select particular tags so that the technique candraw only corresponding parts of the polylines. They canalso select particular tags to be filtered from the display ofthe polylines.
Initially our technique draws only the representativepolylines. Our current implementation generates several
clustering results, with several configurations of the gridand the clustering process. Smoothly replacing the clustering results, our technique seamlessly displays several levels of numbers of representatives.

The technique provides click and sketch interfaces, sothat users can specify interesting representatives by directly clicking or sketching particular shapes. When a userclicks a point on the display, the technique calculates distances between the point and all segments of the drawn
polylines. If at least one of the segments of a polyline isenough close to the clicked point, the technique highlights
the current polyline. When a user draws a curve on thedisplay, the technique samples several points on the curve,and calculates distances between the sampled points andall segments of the drawn polylines. If at least one of thesegments of a polyline is enough close to each of the sampled points, the technique highlights the current polyline.
While polyline reduction in our technique improves
the readability of the data, users may want to look all
the polylines that have the interested features. To satisfy
such requirement, the technique can reactivate the nonrepresentative polylines, which belong to the clusters of
the representative polylines specified by click/sketch operations.
Users can specify particular tags to be extracted by theabove query operations. It can highlight only the parts ofthe polylines corresponding to the specified tags while theclick or sketch operations. Also, it can reactivate only theparts of the non-representative polylines corresponding tothe specified tags.

4 Examples
We developed the presented technique with JDK (JavaDevelopment Kit) 1.6, and executed on a personal com-

(a)

(b)

Figure 3: (a) Overview without tags. (b) Overview with tags.
puter (CPU 2.7GHz Dual Core, RAM 8.0GB) with Windows 7 (64bit). We applied Japanese weather data recorded
by AMeDAS (Automated Meteorological Data Acquisition System) to the presented technique. We extracted
time-varying temperature data observed at 83 points in every 2 hours. We then assigned weather tags including”Clear”, ”Sunny”, ”Cloudy”, ”Rainy”, and ”Snowy” totemperature value of each time of each point.
Our implementation draws the segments of ”Clear”
polylines in red, ”Sunny” in yellow, ”Cloudy” in green,”Rainy” in blue, and ”Snowy” in cyan, interpolating thecolors if tags of two ends of a segment is different. Exceptionally it may draw the segments in gray if we cannot obtain the weather data. While using click or sketch
interfaces, our implementation draws selected polylinesbrightly, and others in gray.
Figure 3 shows an overview of the temperature data.
While Figure 3(a) displays just major and outlier variationsof temperature, Figure 3(b) demonstrates much more information. Colors in the dense parts denote major weather ofthe days. Red or yellow (”Clear” or ”Sunny”) is mainly
observed at the higher peak times of the temperature. Thevariation looks more complicated when less points were”Clear” or ”Sunny”. This result well demonstrates theeffectiveness of the visualization of tagged time-varying
data, since it is difficult to obtain such knowledge fromFigure 3(a).
Figure 4 shows a zoom up view of temperature variation during three days. Figure 4(a) shows the original
view of the tagged temperature data before applying levelof-detail control, and Figure 4(b) shows after the level-ofdetail control. We can observe that temperatures drawn as
blue or cyan polylines continued decreasing for almost 24hours, while temperatures drawn as yellow or green polylines increased in the day times. Figure 4(a) looks somewhat crowded, while Figure 4(b) represents the features ofthe data more clearly. Again, it is difficult to obtain suchknowledge from the visualization results without tags, asshown in Figure 4(c).
Figure 5 shows interactive polyline selection by using
click and sketch interfaces. Figure 5(Upper) shows theresult which we clicked middle-range points while selecting two tags ”Clear” and ”Sunny”; consequently polylines
tagged as ”Clear” or ”Sunny” at the clicked points werehighlighted. It represents that range of temperature between the daytime and the night is relatively large, while(c)(d)(e)Figure 4: (a) Zoom up view with tags, without level-of-detail control. (b) Zoom up view with tags, with level-of-detailcontrol. (c) Zoom up view without tags.
the variation is quite stable. Figure 5(Center) shows the result which we clicked low-range points while selecting twotags ”Rainy” and ”Snowy”; consequently polylines tagged
as ”Rainy” or ”Snowy” at the clicked points were highlighted. It represents that range of temperature between thedaytime and the night is relatively small, and the average
is a bit lower than temperatures of ”Clear” and ”Sunny”.
Also, we can find that extremely lower temperature can beoften observed from ”Clear” or ”Sunny” points. Similar
knowledge can be brought from Figure 5(Lower), which
we clicked low-range points while not selecting any tags,
and consequently polylines which have extremely lowervalues at clicked points are highlighted. Again, we can findthat extremely lower temperature can be often observed
from ”Clear” or ”Sunny” points, while temperature variation is relatively smaller at ”Rainy” or ”Snowy” points atthat times.

of tags.
[Multiple tags at a point:] It is also difficult for our current implementation to represent if multiple tags are simultaneously assigned to a particular time of a particular polyline. Again, we would like to discuss what kinds of visual
metaphor can be more effective for the representation ofmultiple tags.
[Observation of tag-change:] It is interesting for several
kinds of data to observe how time series values vary when
the assigned tags change. We would like to add features
to the technique so that we can focus on time series value
variation with particular patterns of tag changes.
[More applications and tests:] We would like to apply
more various data to the technique, including medical measurement datasets, system measurement datasets, and stock
price datasets. Also, we would like to have experiments for
subjective and objective evaluations of the technique.

5 Conclusion

References

This paper presented a polyline-based visualization
technique for tagged time-varying data. The paper first described the definition of the tagged time-varying data, andpresented techniques for level-of-detail control and interactive polyline selection. It also demonstrated effectivenessof the technique by applying temperature data with weathertags.
Our potential future work includes the following:[Many kinds of tags:] Since our current implementation
represents tags as colors, it may be difficult to visually distinguish if we have many kinds (e.g. more than 10) of tags.
We would like to discuss what kinds of visual metaphor
can be more effective for the representation of more kinds[1] P. Buono, A. Aris, C. Plaisant, A. Khella, B. Shneiderman, Interactive Pattern Search in Time Series,
Conference on Visualization and Data Analysis ’05,
175-186, 2005.
[2] P. Buono, C. Plaisant, A. Simeone, A. Aris, B. Shneiderman, G. Shmueli, W. Jank, Similarity-based forecasting with simultaneous previews: A river plot interface for time series forecasting, 11th International
Conference on Information Visualisation, 191-196,
2007.
[3] H. Hochheiser, B. Shneiderman, Dynamic query
tools for time series data sets: Timeboxwidgets

Figure 5: Interactive selection. (Upper) Polylines tagged as ”Clear” or ”Sunny” at the clicked points are highlighted. (Center) Polylines tagged as ”Rainy” or ”Snowy” at the clicked points are highlighted. (Lower) Polylines which have extremely
lower values at clicked points are highlighted.
for interactive exploration, Information Visualization,
3(1):1-18, 2004.
[4] M. Imoto, T. Itoh, A 3d visualization techniquefor large scale time-varying data, 14th International Conference on Information Visualisation, 1722, 2010.
[5] J. Lin, E. Keogh, S. Lonardi, Visualizing and Discovering Non-trivial Patterns in Large Time Series
Databases, Information Visualization, 4(2), 61-82,
2005.

[6] Y. Uchida, T. Itoh, A visualization and level-of-detailcontrol techniquefor large scale time series data, 13thInternational Conference on Information Visualisation, 80-85, 2009.
[7] C. Wang, H. Yu, K.-L. Ma, Importance-driven timevarying data visuaization, IEEE Transactions onVisualization and Computer Graphics, 14(6):15471554, 2008.
[8] M. Wattenberg, D. Jones, Sketching a Graph to Querya Time-Series Database, SIGCHI Conference on Human Factors in Computing Systems Extended Abstract (CHI2001), 381-382, 2001.