Method, system and computer program product for visually approximating scattered data using color to represent values of a categorical variable

A method, system, and computer program product for a new data visualization tool for determining distribution weights that represent values of a categorical variable and then mapping a distinct color to each of the weights so as to visually represent the different values of the categorical variable (or data attribute) in a scatter plot. The distinct colors of a splat are based on the distribution of categorical variable values in a corresponding bin, the distribution of which is represented by a vector. The vector contains as many locations as the number of different values for the categorical variable. The value stored in each location is typically a weight or percentage for that particular value of the categorical variable. Each location in the vector is also associated with a distinct color. The coloring of a single splat with multiple colors involves the rendering of each vector by looping through each vector location, and then based on the weight stored in that location, randomly selecting the same percentage of triangles in the splat for the color associated with that vector location. A threshold is used to help reduce confusion and decrease processing time by summing all weights below the threshold and assigning to it a single neutral color. A slider or other controller can be used to vary the value of the threshold.

BACKGROUND OF THE INVENTION

1. Field of the Invention

The present invention relates to visualizing scattered data points using a computer display.

2. Related Art

Computer visualization tools are called upon to handle ever increasing amounts of data. Conventional scatter plots visually represent multivariate data points as graphical glyphs plotted along one, two, or three axes. Each data point has one or more data attributes, also called variables. These data attributes can be numerical or categorical. Each axis can represent a different data attribute. Additional data attributes can be represented by varying the color or size of the glyphs.

Problems are encountered in visualizing scattered data when the number of data points is large. In general, each data point in a conventional scatter plot is represented by a corresponding glyph. As the number of scattered data points increases, more glyphs crowd a scatter plot display. The time it takes to render each glyph increases. The time it takes to build and display a scatter plot can become too long, thereby, precluding interactive, on-the-fly rendering of scattered data. Occlusion can also occur as data points in the foreground of a scatter plot hide data points behind them. A serious problem occurs when many data points occupy the same location.

To illustrate the above problem, consider a two-dimensional scatter plot containing millions of data points. It takes a very long time for a graphics processor to draw millions of glyphs covering all these data points. If each data point is represented by a single pixel on the screen, then there will be many overlapping data points. Only the data point for a glyph which is drawn last for a given pixel location will be seen.

T he same problems occur in three-dimensional scatter plots where three-dimensional (3-D) glyphs (e.g., cubes, spheres. etc.) are used to represent data points. These 3-D glyphs are plotted with respect to three scatter plot axes. Rendering such a 3-D scatter plot for large numbers of data points can take a long time, as many glyphs must be processed. Moreover, if there are many data points to be covered, glyphs in the foreground occlude those in the back. Also, data is hidden when the data points are clustered together. There is no easy way to examine data inside a cluster.

What is needed is a data visualization tool that visually approximates a scatter plot when a large number of data points needs to be drawn. Further, what is needed is a visualization tool that handles the case where a categorical variable has been mapped to the color of the scattered data points. To accomplish this using the splatting technique described herein, it is necessary to first determine distribution weights that represent values of a categorical variable in each bin, and then map a distinct color to each of the weights corresponding to the different values of the categorical variable in the scatter plot.

SUMMARY OF THE INVENTION

The present invention provides a method, system, and computer program product for a new data visualization tool for representing distribution weights that represent values of a categorical variable and then mapping a distinct color to each of the weights so as to visually represent the different values of the categorical variable (or data attribute) in a scatter plot. A special type of splat is used to represent the distribution of colored data points in a bin. In an alternate embodiment, distribution weights mapped to distinct colors are used to represent values for a numerical variable. Through a binning process, bins of scattered data points are formed. Each axis of a scatter plot is discretized according to a binning resolution. Bin positions along each discretized scatter plot axis are determined from bin numbers.

According to one embodiment of the present invention, the bins, which represent a cloud of scattered data points, are volume rendered as splats. The opacity of each splat is a function of the number (count or weight) of data points in a corresponding bin. The distinct colors of the splat are based on the distribution of categorical variable values in a corresponding bin. The variable which is mapped to splat colors is typically a variable other than one mapped to a scatter plot axis.

In one example of the present invention, the mapping of a categorical variable to color involves storing a vector of weights (counts) for each bin. (Bins are represented as rows in a table which are computed by aggregating an original data set). The vector is used to represent the distribution of the categorical variable values in the bin. The vector contains as many locations as the number of different values for the categorical variable. The value stored in each vector location is typically the percentage of the total weight of data in the bin for that particular value of the categorical variable. Each location in the vector is also associated with a distinct color. The splat used to represent a bin graphically needs to show the distribution of categorical variable values. The present invention describe a method in which this can be accomplished. The method involves a random set of opaque triangles, where a percentage of the triangles are of each color, and the total number of triangles map to bin weight. The coloring of a single splat with multiple colors involves the rendering of each vector by looping through each vector location, and then based on the weight stored in that location, randomly selecting the same percentage (or weight) of triangles in the splat for the color associated with that vector location.

According to a further feature of the present invention, a threshold is used to help reduce confusion and decrease processing time by summing all weights below the threshold and assigning to it a single neutral color. A slider or other controller can be used to vary the value of the threshold.

According to another embodiment of the present invention, interpolated data is used for animating an external query attribute of a scatter plot of data points in a computer system. An external query device (or slider) corresponding to an attribute of the data points is used to animate over that data attribute. If the slider control is positioned in between discrete positions of the slider, the displayed plot corresponds to interpolated data. First adjacent data structures (or data tables) are determined corresponding to the position of the external query means. The adjacent data structures are merged together, then aggregated the using the spatial columns of the data structure as a unique key. For a categorical variable, weights (or percentages) of the same value in vectors to be merged get aggregated together. An interpolated bin is generated, where the count (or weight) of the bin is interpolated and the weights in the vector is also interpolated, but weighted by the new count. The interpolated vector is mapped to color in the visualized scatter plot. The plot appears as rendered splats corresponding to bin positions of the interpolated bins, where each splat has an opacity that is a function of the interpolated count of data points in the corresponding bin. The present invention allows for the smooth animation of one or more external query attributes of the data points.

DETAILED DESCRIPTION OF THE EMBODIMENTS

1. Overview and Terminology

The present invention provides a new data visualization tool that visually approximates a scatter plot, provides smooth animation of graphics by using interpolated data and adequately represents a categorical data attribute that is represented by varying colors of the scatter plot. Bins, representing clouds of scattered data points, are volume rendered as splats. The opacity of each splat is a function of the density of data points (e.g. the count or number of data points) in a corresponding bin. The color of the splat represents a data attribute associated with the data points in a corresponding bin.

The following terms are used to describe the present invention:

Data, data points, scattered data, multivariate data., and equivalents thereof, are used interchangeably to refer to a data set having corresponding data attributes (also called variables) that are suitable for a multivariate data visualization, such as, a scatter plot. One data point can contain multiple data attributes. Data attributes are represented as numerical or categorical variables in each axis of a scatter plot. Numerical variables can include any type of numerical value or range (e.g. real numbers or integers). Categorical variables have nominal values like text strings. For example, a data attribute representing color can include the following categorical variable values: red, blue. and orange. Numerical values can also be assigned to each categorical variable value for sorting and other operations (i.e. red can be set to 1, blue can be set to 2, and orange can be set to 3).

A 1-D scatter plot has one axis plotting one variable. A 2-D scatter plot has two axes plotting two variables. A 3-D scatter plot has three axes plotting three variables. Any type of data can be used, including but not limited to, business, engineering, science, and other applications. Data sets can be received as data records, flat files, relational or non-relational database files, direct user inputs, or any other data form, Binning refers to any conventional process for aggregating scattered data points into bins. Bins can be made up of uniform and/or non-uniform clusters of data points. Splat (also called a footprint) refers to any transparent shape used to build a transparent volume. For example, splats, when composited in a back to front order relative to an eye point (or a front to back order), can be used to reconstruct transparent volumes.

Splats used in the present invention can include, but are not limited to, Gaussian splats. A Gaussian splat is one that is most opaque at its center and approaches zero opacity, according to a Gaussian function in every radial direction. A Gaussian splat is typically approximated with a collection Gouraud shaded triangles, or more accurately, as a texture mapped polygon (e.g. rectangle).

Splats used in the present invention can also include, but are not limited to, the examples of splats described in the following articles (each of which is incorporated by reference herein): L. Westover, Footprint Evaluation for Volume Rendering , Proceedings of SIGGRAPH '90, Vol 24 No 4, pp 367-376; Lauer and Hanrahan, Hierarchial Splatting: A Progressive Refinement Algorithm for Volume Rendering, Computer Graphics , vol.25, No.4, July 1991, pp.285-289; and Crawfis and Max, Texture Splats for 3D Scalar and Vector Field Visualization , Proceedings of Visualization 1993, p 261-265. For instance, a splat can be drawn as a collection of Gouraud shaded triangles (see, e.g. the Lauer and Hanrahan 1991 article), or as texture mapped rectangles (see, e.g., the Crawfis and Max 1993 article).

FIG. 7A shows an example of a Gaussian texture 700 that can be texture mapped by a graphics engine to form a textured splat. FIG. 7B is a graph of the opacity of Gaussian texture 700 illustrating the variation in opacity from a peak at the center to zero according to a Gaussian function.

An external query device or slider is used to vary the display of data in an external dimension. A slider is often a button or dial which a user moves along a scale to set the data visualization to a different value or range of values in the external dimension. A complete description of external query sliders is provided in the related '548 application, by G. Sang'udi, et al. (incorporated by reference above).

2. Example Environment

The present invention is described in terms of an example computer graphics and data mining environment. Given the description herein, it would be obvious to one skilled in the art to implement the present invention in any general computer including, but not limited to, a computer graphics processor (single chip or multiple chips), high-end to low-end graphics workstations, virtual machine (e.g. Java-created application), and network architectures (e.g., client/server, local, intermediate or wide area networks). In one preferred example, the present invention can be implemented as software, firmware, and/or hardware in a data mining tool, such as, the Mineset product released by Silicon Graphics, Inc., and executed on a graphics workstation manufactured by Silicon Graphics, Inc. (e.g. an Indigo 2 , Indy, Onyx, or O 2 workstation). A further example computer system is described below with respect to FIG. 5 , but is not intended to limit the present invention.

Description in these terms is provided for convenience only. It is not intended that the invention be limited to application in this example environment. In fact, after reading the following description, it will become apparent to a person skilled in the relevant art how to implement the invention in alternative environments.

3. Visually Approximating Scattered Data

FIG. 1 shows a routine 100 for visually approximating scattered data according to the present invention. For clarity, the steps of routine 100 will be described in general terms and with reference to a specific example. The specific example uses a sample ore data set of data records related to ore samples extracted from a mining site, as shown in the table below:

In step 110 , each scatter axis variable is discretized according to a binning resolution to form bins. In general, any conventional binning technique (uniform or non-uniform) can be used to bin numeric (i.e. real-valued) attributes and categorical attributes. If a categorical attribute is mapped to an axis then the binning is defined to be the distinct values of that attribute. or some grouping of these values based on metadata.

Preferably, uniform bins are created for each variable (or data attribute) that is mapped to a scatter axis. Non-uniform bins can also be formed. In one simple example, each axis of a scatter plot can be discretized into k bins, where k is a positive integer. In a 2-D case, k 1 *k 2 bins (or buckets ) are available for aggregating data points on two respective discretized axes. In a 3-D case, k 1 *k 2 *k 3 bins are available for aggregating data points on three respective discretized axes. Binning is performed as part of pre-processing to reduce processing during rendering.

Bin positions are then determined from the bins (step 120 ). Bin positions define the order of bins along each discretized axis and can be determined from bin numbers associated with the bins. For a numeric attribute, the bin numbers are determined from the discretized real-values, that is, sorting the bins based on the discretized real-values and determining corresponding bin positions. For a categorical attribute, the bin numbers are determined from the distinct values of that attribute. The order of bins (and corresponding bin positions) along a discretized axis can be determined by sorting the distinct categorical values in any number of different ways. For example, sorting methods can include. but are not limited to, sorting based on alphabetical or numeric order, sorting based on count, or sorting based on an aggregate value (e.g. average) of the attribute mapped to color.

A count of the number of scattered data points aggregated into each bin is determined (step 130 ). An aggregate value that represents a data attribute of the scattered data points in a bin is determined for each bin as well (step 140 ). The aggregate value in one preferred example is an average value of a data attribute of scatter data points in a bin. The aggregate value can also be a minimum, maximum, median, count, or any other value representing a data attribute of scatter data points in a bin. The aggregate value can represent an external variable not mapped to an axis or a data variable that is mapped to an axis. There could be multiple value columns in Tables 1 and/or 2, each value column representing a different data attribute. In the splat plot visualization as described below, it is a simple matter to select among the value columns for purposes of mapping the color without doing any additional computation.

A data structure can be created to store bin position, count, and value data for each bin as determined in steps 120 to 140 , respectively. For example, a new table having records corresponding to bins and data attributes representative of the bins (e.g. bin position, count. and value of an external attribute) can be created. An example new binned table drawn from the sample ore data set of Table 1 for three-dimensions (longitude, latitude, and depth) is shown below:

Next, in step 150 , splats representative of the bins are rendered in a graphics engine. A splat is drawn at each bin location to form an image that visually approximates an original scatter plot of the data. Splats are rendered in a back-to-front order (or front-to-back order) during compositing such that splats located furthest from a display screen are rendered before splats located closer to a display screen.

For each bin, the count of scattered data points aggregated in the bin is mapped to a splat opacity (step 160 ). In one example, a graphics engine texture maps the opacity value across a polygon to represent a splat.

In one preferred embodiment, the splat opacity is a function of the count of aggregated data points in a corresponding bin as determined by the following equation:

where, opacity represents the opacity value of a splat at its center, count represents the count of aggregated data points in a corresponding bin, u represents a global scale factor, and exp denotes an exponential function (such as, an exponential function having a natural logarithm base e). The above exponential opacity function is effective in modeling light propagation through clouds of light emitting spheres.

A slider or other controller can be used to vary the value of the global scale factor u. This allows globally scaling of the opacity for each splat to make an entire display image of rendered splats more or less transparent. This scaling by the global scale factor, while impacting the entire image, is not linear. A splat's opacity is scaled differently depending upon its count, that is. the number of data points the splat represents.

FIG. 6 is a graph showing the above opacity function using large and small global scale factors. In particular, the opacity value for a splat is an exponential function of the count of the scattered data points that approaches an asymptotic limit 1 for large counts. The global scale factor is set to a value (i.e. large or small) for a particular image. As shown in FIG. 6 , when a large global scale factor is used, each splat's opacity approaches the asymptotic limit 1 more quickly (for lower counts) than a small global scale factor.

In step 170 , the value representative of a variable associated with the aggregated data points in a respective bin determined in step 140 , is mapped to a color value. For example, a color transfer function can be used to map an average value of a numeric external variable for each bin. Each splat is then rendered with a color value that is a function of the external variable associated with the aggregated data points in a respective bin.

Finally, the splats are composited to form a volume rendered image on a display screen (step 180 ). The image includes the rendered splats with opacity and color determined according to steps 150 - 170 . The splats are plotted along discretized scatter axes at bin positions determined in step 120 . In this way, the volume rendered image is a splat plot that visually approximates the scattered data points.

FIG. 2 shows an example color image of a two-dimensional splat plot 200 that uses splats to visually approximate scattered data according to the present invention. Splat plot 200 was generated using the sample data described above with respect to Tables 1 and 2.

A display window 205 includes a slider 210 and two thumb wheels Rotx, Roty for manipulating the orientation of the two-dimensional splat scatter plot 200 . Slider 210 globally alters the opacity of splats in the two-dimensional splat scatter plot 200 . Thumbwheels Rotx and Roty rotate the image about horizontal and vertical axes respectively. Other controls (not shown) for manipulating the plot 200 such as, magnifying, reducing, or shifting the image can be used. Finally, a legend is provided to show what the opacity and color of the splats represent (e.g. opacity represents a count value and color represents an average value, 0-15 is mapped to blue, 15-30 is mapped to green, 30-45 is mapped to yellow, and 45 and above is mapped to red).

FIG. 3 shows an example color image of a three-dimensional splat plot 300 that uses splats to visually approximate scattered data according to the present invention. Splat plot 300 was generated using the sample data described above with respect to Tables 1 and 2. FIG. 4 shows a close-up view 400 of the color image of FIG. 3 which further shows an example of textured splats.

According to a further feature of the present invention, a dragger object is displayed to permit a user to select different regions inside the splat plot 400 . The dragger object is shown in this example as a relatively opaque cylinder having reference axes that are parallel to the displayed scatter axes. The draftier object can be manipulated by a user through a mouse or other user-interface control.

Information about a selected region at which the dragger object is located can then be displayed. This information can include the values of the data attributes of the bin at or nearest to the selected region. See, e.g., the top window 450 in FIG. 4 which shows information on interior binned data points at the location of the dragger object, namely, longitude 6571.99-6576.81, latitude 22090.8-22099.1, depth bin 10107.3-10122.6. By moving and selecting different regions using the dragger object, a user can navigate inside a volume rendered image. By reading window 450 a user can scan information on interior binned regions.

According to another embodiment of the present invention, volume rendering involving ray tracing or cell projection can be used to represent bins of aggregated data points. For ray tracing, volumes (e.g. polygons) are rendered by using bin centers as vertices. The bin positions containing no data are assumed to have zero density (completely transparent). At bin positions where data is present, the density is directly proportional to the count of scattered data points. See. e.g., the use of ray tracing in volume rendering in the reprinted article by Levoy, Display of Surfaces from Volume Data, IEES Computer Graphics and Applications , vol. 8, No. 5, May 1988, pp. 29-37 (reprinted pages 135-43) (incorporated herein by reference).

For cell projection, cubes are constructed by using, bin centers as vertices. Again, if a bin with no data is needed as a vertex to complete a cube, that vertex will have an opacity equal to zero. The opacity assigned to the vertices is then a function of the count of scattered data points in a corresponding bin, according to the following equation:

where, opacity represent the opacity value of a cube, count represents said count of data points in a corresponding bin, u represents a global scale factor, and exp denotes an exponential function. The transparent cubes arc rendered directly or by using tetrahedral decomposition in a back to front order. See, e.g., the use of cell projection in volume rendering in the articles by Wilhelms and Van Gelder, A Coherent Projection Approach for Direct Volume Rendering, Computer Graphics , vol. 25, No. 4, July 1991, pp. 275-284 (incorporated herein by reference) and Stein el al., Sorting and Hardware Assisted Rendering for Volume Visualization, IEEIE 1995, pages 83-89 (incorporated herein by reference).

4. Distribution of Categorical Variable Values Mapped to Color

The present invention provides a method, system and computer program product for a new data visualization tool for visualizing large numbers of records with a particular emphasis on categorical variables (or data attributes) that are mapped to color. In an alternate embodiment, the splat color is determined by averaging a numerical variable. As described above, each data point in a scatter plot has one or more variables. Variables can be either numerical or categorical. Categorical variables have nominal values like text strings. For example, a categorical variable representing the make of a car can include the following values: American, German, Japanese, Canadian., and French. Variables can be represented by a scatter plot axis or by being mapped to color. Variables mapped to color are not mapped to a scatter plot axis.

The routine 100 ( FIG. 1 ) described above for visually approximating scattered data explained how to map a numerical variable to color. Specifically, in step 140 , an aggregation (e.g., average) value that represents a numerical variable is determined for each bin. Then in step 170 , a color transfer function is used to map this average value to a color value for each bin. The result is that when each bin is volume rendered as a splat, each splat is a single color that visually represents the average of the numerical variable. This works well because numerical data is continuous. It should be apparent to one skilled in the art that this approach for numerical variables does not work for categorical variables, such as the make of a car, because the concept of an average is meaningless. Thus, the present invention provides a solution for visualizing information related to a large number of records with categorical variables mapped to color.

The approach of the present invention to map a categorical variable to color involves storing a vector at each record (i.e. bin). The vector is used to represent the distribution of the categorical variable values in the bin. The vector contains as many locations as the number of different values for the categorical variable. For example, the vector for the make of a car above. will have five locations. One to represent American, one to represent German, and so forth. The value stored in each location is typically a percentage of the total weight in that bin for the particular value of the categorical variable. Another reason for storing the total bin weight is to determine the opacity and for alternating the number of triangles. To further illustrate this embodiment of the present invention, an example is utilized. The specific example is a sample car data set of data records related to the performance of cars in the market today, as shown in Table 3 below.

TABLE 3 Original Data MPG Horsepower Make 23 135 American 30 250 German 29 250 German 23 150 Japanese 24 140 French 30 135 French 26 130 Canadian 22 140 Japanese 23 145 Japanese 29 135 American 21 160 Canadian Each data record has three variables characterizing each car sample including mpg, horsepower and make. Of course, many other variables could also be included in Table 3. In order to visually represent the relationships between these variables, the following method can be used. The processing steps (specifically steps 110 , 120 and 130 ) described above in connection with FIG. 1 can be utilized to process the original data stored in Table 3. First, variable values to be mapped to axes or sliders are binned. For this example, mpg and horsepower represent the x and y axes in a 2-D plot. The present invention works in a similar manner for 3-D plots. In this example, a first step is to bin the variables mpg and horsepower to a desired resolution (see step 110 ). As described above, binning can be accomplished using known decision support or mining tools having this operation. It is not possible to bin the categorical variable make. This variable is to be mapped to color. After bin positions are determined (see step 120 ), an aggregation is performed to compute counts or weights (see step 130 ).

As described above in reference to FIG. 1 and step 140 , the value of the numeric variable to be mapped to color is averaged for each bin. The present invention alters step 140 to provide a solution for mapping the values of a categorical variable to color. According to the present invention, a distribution technique is performed that represents the distribution of categorical variable values for that bin. This distribution technique is shown in FIG. 12 (replacing step 140 ). As shown in FIG. 12 , after processing steps 110 to 130 described above with reference to FIG. 1 , the n number of different values of the categorical variable for the bin is determined in step 1210 . This determination step can be made in response to a user input or an automatic setting, such as, a default value. For the make variable above, n is five in step 1210 because five different values exist including American, German, Japanese, Canadian, and French. This determination is performed automatically by computing the number of distinct values in a set of records to determine the total number of possible values of a categorical variable.

In step 1220 , a vector is created with n locations. In the present example, a vector with five locations is created for each bin. In step 1230 , each categorical variable value is associated with one of the vector locations. For simplicity, Table 4 below shows each value being represented in the vector by its first letter (e.g., A for American, G for German, and so forth). In step 1240 , the distribution or weight of each value in the bin is calculated. One way to represent the weight is by the percentage of each value in the bin. For example, if one-fifth or 20% of the value American is present in the bin, then 20 is the weight calculated in step 1240 . This weight is stored in the location associated with A. These aforementioned steps result in Table 4, shown below.

At this point the routine of FIG. 12 is completed (replacing step 140 of FIG. 1 ). Next, splats representative of the bins are rendered in a graphics engine (see step 150 ). For each bin, the count of scattered data points aggregated in the bin is mapped to a splat opacity or number of small opaque triangles in a fixed texture of triangles (see step 160 ). As mentioned above, a graphics engine texture maps the opacity value across a polygon to represent a splat.

As described above in reference to FIG. 1 and step 170 , a color transfer function is used to map an average value (relating to a numerical variable) to a color value for each bin. The result is that when each bin is volume rendered as a splat, each splat is a single color that visually represents the average of the numerical variable. As stated above, this approach does not work for categorical variables because the concept of an average is meaningless. The present invention alters step 170 for categorical variables mapped to color. For categorical variables, each location in the vector (in each bin) must be mapped to a distinct color. Each distinct color represents a different categorical variable value. for example, assume the following vector from Table 4 is to be mapped to color:

As described above, each value (e.g. American, Gerian, etc.) has equal distribution or weight in the record. Thus, each distinct color in the splat will be weighted equally (i.e., the splat will be colored with 20% of five different colors). The ability to color a single splat with multiple colors requires that the splat texture map be divided into some number of distinct regions. In one example, these regions take on the shape of triangles, where each triangle has the same area as all other triangles in the splat. Therefore, step 170 is altered to allow for the rendering of each vector by looping through each location, and then based on the weight stored in that location, selecting the same percentage (or weight) of randomly placed triangles in the splat texture for the color associated with that location. The result is changes in color within the splat that can be seen on a pcr triangle basis. FIG. 13 shows an example color image (or a checkerboard background) of a 2-D splat 1300 where the splat is colored with 20% of five different colors.

According to one feature of the present invention the orientation of the splat is random. This random orientation helps to avoid disturbing and irrelevant patterns in the data due to the regular binning of data or the regular coloring of the triangles. FIGS. 14 and 15 help to illustrate this point. FIG. 14 shows an example color image of a 2-D plot 1400 whose splats were oriented in a fairly uniform pattern of constant proportions. Plot 1400 is colored to reflect the equal distribution of the categorical variable values. Notice the undesirable regular pattern artifacts present in plot 1400 . In contrast FIG. 15 shows an example color image of a 2-D plot 1500 (having the same distribution as FIG. 14 ) whose composite splats were randomly selected.

In the above example from Tables 3 and 4, the distinct colors where limited to five because the make categorical variable was limited to five values. It is easy to recognize that other real data may have many distinct data values. This could result in a plethora of distinct colors with very small weights stored in each location of a vector. To reduce the confusion that would result from this, the present invention pre-filters the data and sums all weights below a certain threshold lumping them into a single value labeled other. The use of a threshold also helps to avoid the computational expense of rendering so many values in a bin.

The technique allows only the categorical data values with weights greater than a user specified percentage threshold to be represented in the splat. By representing only these values, a problem arises on how to represent the correct proportion of each value within the splat. For example, if a vector contains several weights that are 5% or less, and three additional values which are of 8%, 13% and 21% of the bin's weight, it is desirable to have the splat faithfully represent the 8%, 13% and 21%, while obfuscating the remaining weights. Note that by scaling the 8%, 13% and 21% proportions up to cover 100% of the triangles in the splat it will lead to misinterpretations of the data.

The present invention solves this problem by grouping the remaining weights that are not to be represented in the splat into a new single value and assign this value a distinct neutral color (e.g., gray). The weights within the vector still add up to 100%. An illustration of this technique is explained in reference to FIGS 16 A and 16 B. In FIG. 16A , vector 1610 represents the distribution of a categorical variable that has 21 different values. These values arc represented by a through u. If the threshold is set at 6%, then vector 1610 contains 18 values with weights less than 6%. The present invention combines these weights and assigns a new value ( other, for example). This is illustrated in FIG. 16 B. Vector 1620 represents the same categorical variable as FIG. 16A with the 18 values combined into one value represented by new value other. The weight of other is 58, the combination of all the weights less than threshold 6. Here, 58% of the triangles in the splat will be colored a neutral color. As seen in FIGS. 17 and 18 , the color gray is associated with this new value. FIG. 17 shows an example color image of a 2-D splat 1700 that has a threshold of 15%. This means that only colors which have 15% or greater of the bin weight get shown. All others are colored gray. FIG. 18 shows an example color image of a 2-D splat 1800 that has a threshold of 40%. Here, only colors which have 40% or greater of the bin weight get shown and all others are colored gray.

Referring again to vector 1610 of FIG. 16A , the 21 different values represented by a through u each have a different color associated with it. For example, the value a may represent the color red, the value b may represent the color purple, and so forth. As shown in vector 1620 of FIG. 16B , once all weights below a threshold are combined not every value is represented in the vector. For example, vector 1620 no longer represents the value a. A problem arises on how to identify the correct color of each value in the vector. The present invention solves this problem by storing a single table in memory that identifies the corresponding color of each value of the categorical variable. An example of such a table for vectors 1610 and 1620 is shown below:

dark light light red purple blue yellow blue . . . green orange gray a b c d e . . . t u other Each bin in the table has an index into this table. This saves computer memory because each bin in the table does not have to store the corresponding color of each value of the categorical variable.

A slider or other controller can be used to vary the value of the threshold. This allows for the global scaling of the color or distribution for each splat to make an entire display image of rendered splats more or less neutral in color. This scaling by the threshold, while impacting the entire image, is not linear. A splat's coloring is scaled differently depending on the weights within its vector, that is, the distribution of categorical variable values the splat represents. Although the present invention was illustrated in reference to a 2-D plot, the basic approach described above is identical for a 3-D plot.

5. Interpolation of Nutmeric and Relational Data sets

The present invention describes a method, system, and computer program product that provides smooth animation of graphics between approximated scatter plots of numeric and/or relational data sets for the purpose of animation along several dimensions. Most scientific volumetric data sets have several independent attributes (variables) which correspond to spatial dimensions, a possible time dimension (usually used for animation), and one or more dependent variables (scalar, vector, or tensor) which have real values defined throughout the domain of the independent variables. As discussed above, one of these scalar values can be mapped to color when volume rendering. Also discussed above, is a method of mapping categorical variable values to color when volume rendering.

Unlike physical data sets, relational databases have many attribute columns that are categorical (e.g., education, occupation) rather than numerical. Thus, relational databases may not have attributes (variables) that map directly to physical parameters, such as time, space, or density. According to the present invention, for purposes of visualization, assignments can be given to relational databases so that otherwise abstract quantities can be well understood.

As mentioned above, any conventional binning technique (uniform or non-uniform) can be used to bin numeric (i.e. real-valued) attributes and categorical attributes. If a categorical attribute is mapped to an axis then the binning is defined to be the distinct values of that attribute, or some grouping of these values based on metadata. In the present invention, for example, uniform binning can be used to discretize the real variables mapped to spatial axes and to create independent slider dimensions. Unique values can define the bins for categorical axes. According to a preferred embodiment of the present invention, a table is used as a data structure for representing the visualization.

To further illustrate this embodiment of the present invention, an example of a relational data set is shown below. Table 5 displays a set a related variables before processing. In this example, Table 5 contains approximately 150,000 rows of data. The variables shown in Table 5 include income, education, occupation, age, hours worked, and marital status. Of course, many other variables could also be included in Table 5.

TABLE 5 Original Data Hrs Income Education Occupation Age worked Marital Status 0 HS-grad Other-services 46 5 Divorced 0 HS-grad Other-services 46 5 Married 37440 Bachelors Exec-man . . . 57 50 Married 0 Preschool Craft-repair 5 0 Separated 27300 Bachelors Adm-clerical 23 40 Single 24410 HS-grad Craft-repair 24 42 Single 59127 HS-grad Tech-support 40 40 Widowed 5000 9th Adm-clerical 66 12 Spouse Absent In order to visually represent the relationships between these variables, the following method can be used. The processing steps (specifically steps 110 , 120 , 130 , and 140 ) described above in connection with FIG. 1 can be utilized to process the original data set stored in Table 5. First, any numeric values that are to be mapped to axes or external query dimensions are binned. For this example, education level ( education ), occupation. and hours worked per week ( hours worked ) represent the x, y, and z axes in a plot. Age will be shown as an external query slider, thus allowing changes in distribution as age is varied. In this example, a first step is to bin the variables age and hours worked to a desired resolution (see step 110 ). As described above, binning can be accomplished using known decision support tools having this operation.

A dependent variable, income, is left unbinned: this variable is to be mapped to color. Alternatively, the categorical variable marital status could be mapped to color. After bin positions are determined (see step 120 ), an aggregation is performed to compute counts (see step 130 ). Additionally, averages for income are computed using the binned and numeric variables as keys (see step 140 ). As discussed above. because categorical variable marital status is to be mapped to color, a vector of weights is computed for each bin. For simplicity, Table 6 below shows each value of marital status being represented as follows: a for married, b for divorced. C for separated, d for single, e for widowed, and f for spouse absent. These aforementioned steps result in Table 6, shown below.

TABLE 6 Processed Data Hours Average Education Occupation Age worked income Count Marital Status HS-grad Tech-support 20 20 2543.8 4 HS-grad Tech-support 20- 30 35-40 23927.2 53 HS-grad Exec-man... 20 45-50 23000.0 1 HS-grad Exec-man... 20- 30 20 20996.5 3 HS-grad Exec-man... 20- 30 25-30 7500.8 2 HS-grad Exec-man... 20- 30 30-35 19086.4 2 HS-grad Exec-man... 20- 30 35-40 29863.0 17 HS-grad Exec-man... 30- 40 40-45 25946.2 58 Masters Machine-op 50- 06 20 17269 1 Masters Machine-op 70 25-30 37644 1 Masters Machine-op 20- 30 35-40 0 1 Masters Machine-op 20- 30 40-45 20000 1 Preschool Priv-house... 20- 30 20 0 2 Preschool Priv-house... 40- 50 25-30 0 1 Preschool Priv-house... 40- 50 35-40 5000 2 Preschool Priv-house... 60- 70 30-35 12200 1 As shown in Table 6, after processing there are up to three columns for I10 variables mapped to axes in a 3-D plot. These columns are education, occupation, and hours worked. There is also one column (here, the count column) corresponding to the number of data points in each row (or bin). This sum of record weights in a bin is used to determine opacity. There is one numeric column (here, the income column) which represents the average value of aggregated data in each bin. This income column is used to map color. The categorical column representing marital status could alternatively be used to map color. Finally, there may be additional columns corresponding to other variables which are to be used for external slider dimensions (or other external interactive query devices for interactively selecting slices of the multi-dimensional space). In this example, the age column is used for this purpose. Alternatively, in some cases, it may be desirable to weight records by the value of some other variable, rather than simply counting once for each record. For example, there may be a row for every town in a geographical region and a column for population. In this case, each record can instead be weighted by population.

Binning and aggregation can be performed as part of preprocessing. For example, according to one embodiment of the present invention, this preprocessing can be performed on the server where the database resides. Only a processed table, such as Table 6, need be returned to the client for visualization. For example, Table 6 represents a processed Table having approximately 4,800 rows and 6 columns, where the original Table 5 included approximately 150,000 rows and 200 columns.

FIG. 8 shows a sample splat plot visualizing the processed data from Table 6. Here, the spatial axes are occupation, education, and hours worked. Income is mapped to color, as indicated by the color scale shown at the bottom of the plot. The external slider in the upper right quadrant of FIG. 8 is used to animate over age. The splat plot shown in FIG. 8 represents data for persons aged 40-50 years old.

In order to visually represent trends in the data, it is useful to animate the visualization over a particular variable. Preferably, this animation is accomplished by tracing a path on one of the external slider dimensions. In this example. as shown in FIG. 8 , the age dimension is binned to provide a densely populated scatter plot at any of a finite number of positions along the slider. Recall that if the binning is too highly resolved the resulting image can be too noisy to give a useful image. High resolution binning reduces the count in each bin and hence the statistical significance. With more data, more highly resolved binning is possible without loss of usefulness. According to the present invention, between discrete slider positions, scatter plots are interpolated in order to provide smooth animation.

According to this embodiment of the present invention, there can be a separate table for each binned positioned on an external query slider (representing a continuous variable). In this example, age is used as the slider dimension, which corresponds to 7 separate bins or discrete external slider positions (e.g., under 20, 20-30, . . . , and 60 and over). The separate tables generated corresponding to adjacent bins on an external slider need not have the same number of rows because the differences in data distribution change from one position to the next. For example, in FIG. 8 , if the visualization is changed from showing 40-50 year olds to showing 50-60 year olds by moving a slider control one discrete position to the right, some bins may contain data where there was none before, and vice versa. Recall that each row in a table corresponds to a bin.

According to the present invention, an interpolation technique is performed to provide animation of an external query attribute. For example, this interpolation technique can be performed in an interpolation module that is part of a computer graphics environment. This interpolation technique is shown in flow chart form in FIGS. 9A and 9B . As shown in FIG. 9A , after processing steps 110 to 140 , described above with reference to FIG. 1 , a variable t is set (step 910 ). This t variable corresponds to a slider control position between two discrete external slider positions. Next, adjacent data structures are determined based on the external slider control position (step 920 ). In this embodiment, data tables are utilized as the data structures. Then, the adjacent data structures are merged together (step 930 ). Once the adjacent data structures arc merged, interpolated bins are generated for those bins with the same spatial axes columns (step 940 ). Subsequently, splat representatives are rendered and displayed, as described above with respect to steps 150 - 180 shown in FIG. 1 .

For example for interpolation on a one dimensional (1-D) external slider, two adjacent tables are merged together, then aggregated using the spatial axes columns as unique keys. The count is then linearly interpolated. A zero ( 0 ) count is assumed if one of the tables lacks a particular row. An average value used for color is also interpolated, but weighted by the count. In the case of categorical variable values, we must interpolate the distribution represented by weights in the vectors. These steps are illustrated below in Tables 5-8.

In this example, Table 7 and Table 8 represent adjacent age bins, where Table 7 corresponds to age value 20-30 and Table 8 corresponds to age value 30-40. Each Table also corresponds to a particular position on the external slider scale (e.g., the second and third discrete positions on the external slider shown in FIG. 8 ). According to the present invention, an image representing an interpolated scatter plot can be provided corresponding to any given position along an external slider scale.

In this example, a variable t is used to represent an intermediate position along the slider scale a user chooses. Thus t can range from zero (0) to one (1). In this example, a value of t 0 corresponds to the slider control being located on the second discrete position of the slider scale, and a value of t 1 corresponds to the slider control being located on the third discrete position of the slider scale. Additionally, only a few bins of adjacent Tables 5 and 6 are shown for simplicity.

As illustrated in FIG. 9B , an interpolation routine can be described as follows. As part of step 930 (merging adjacent data structures together), a new count column is added (step 931 ) to Table 7. This new count column is equal to (l t)count. Next, a new weighted value column is added (step 933 ) to Table 7. The new weighted value column is equal to (l t) (count) (value). Similarly, a new count column is added (step 932 ) to Table 8. This new count column is equal to (t)(count). A new weighted value column is also added (step 934 ) to Table 8. This new weighted value column is equal to (t) (count) (value). A new weighted value for the marital status column is also added. Here, for each location in the vector, the weight associated with it gets set equal to (t)(count)(weight). These two new tables are merged together. For t 0.5 (corresponding to a mid-point position between the second and third discrete positions on the slider scale), the merged data appears as illustrated below in intermediate Table 9.

All of the unique rows have been identified using the spatial axes columns as keys. For example, the first and second bins of Table 9 have identical spatial axes columns (HS-grad, Exec-Man., and 15-25 hrs.). In order to perform interpolation, the two new columns (columns 6 and 7 of Table 9) are aggregated by summation (step 935 ). As a result, no two rows have the same binned values for all the spatial axes. In other words, the first and second bins of Table 9 are merged into a single bin. Recall that a zero ( 0 ) count is assumed if one of the tables lacks a particular row. This interpolated bin is generated by dividing the summed value by the summed count to generate the interpolated values (step 945 ). In this case the interpolated values are for income. Here, the interpolated value for the first and second bins of Table 9 is determined by: (25000 35000)/(1.5) 40000. In the case where the interpolated values are for marital status, the interpolated weights (in the vector) for the first and second bins are determined by: (10 6)/(1.5) 10.7 for value a; (20 14)/(1.5) 22.7 for value b; (20 0)/(1.5) 13.3 for value c; (30 12.5)/(1.5) 28.3 for value d; (10 12.5)/(1.5) 15 for value c; and (10 5)/(1.5) 10 for value f. Note that the percentages (or weights) in each vector still add up to approximately 100 percentage after the interpolation. The resulting interpolated data used for plotting (step 950 ) the interpolated scatter plot (for t 0.5) is illustrated below in Table 10.

TABLE 10 Interpolated Table Hrs Education Occupation worked Income Count Marital Status HS-grad Exec-Man. 15-25 40000 1.5 HS-grad Mach-op 45-55 30000 .5 Masters Technician 25-35 35000 1.5 Vocational Mach-op 35-45 40000 1 . . . . . . . . . . . . . . . Thus, at a mid-point between the second and third discrete positions of the external slider scale, an image corresponding to the interpolated values shown in Table 10 is presented to a viewer. The interpolated counts are mapped to splat opacity (step 960 ). The interpolated weighted values are mapped to color (step 970 ). Finally, the splat plot at the midpoint slider control position is displayed to a viewer (step 980 ). In this example, the opacity of a particular splat corresponding to a particular bin is proportional to the count shown in column 5 of Table 10.

According to the present invention, a similar interpolation routine is performed if the external query slider has two dimensions. FIGS. 10A and 10B illustrate resulting images when bilinear interpolation is used. In this example, the illustrated census data set contains approximately 150,000 rows. The spatial axes shown are industry, occupation, and education, where age and hours worked are the external slider dimensions (the horizontal and vertical scales, respectively). An example 2-dimensional (2-D) external slider summary window with corresponding vertical and horizontal external sliders is shown in the upper right quadrant of FIGS. 10A and 10B . As described above, the purpose of the external slider is to allow navigation through, and show the density of the data for additional dimensions in the data. Grid points are displayed in the summary window to aid in the querying and navigation of data in the summary window. A user can query data by horizontal and vertical moving slider controls to vary the external dimensions at which data visualization is displayed. The summary window allows the user to preview specific regions of interest in which to move the slider controls, thereby allowing the user to target the data query more efficiently. The data visualization will then be updated based on the processes described above to reflect the actual or interpolated data at the point selected by the user. As shown in FIGS. 10A and 10B , the red regions in the summary window represent places where the data is dense, while white shows data areas that are sparse.

For example, FIG. 10A shows the 2-D external slider controls as selecting two 3-D slices of the data: people who are aged 40-50 and work 35-45 hours per week. The image in FIG. 10A is fairly opaque because the point selected by the user corresponds to a place where the data is dense. In contrast, FIG. 10B shows the 2-D external slider controls as selecting people who are aged 50-60 and work 55-65 hours per week. The resulting image is much less opaque because the point selected by the user corresponds to the sparse data (as indicated by the white regions of the summary window). When the slider controls are positioned over a black point within the summary window, the image shows uninterpolated data. If the slider is positioned over an intermediate region within the summary window, the image shows interpolated data generated by the processes described above.

According to the present invention, a user can trace out a path on the slider and animate over it using the tape player like control panel located directly below the horizontal slider scale in FIGS. 10A and 10B . Furthers it may be possible to have the volume rendered scatter plot itself act as an external slider to a second scatter plot or other visual tool.

Also according to the present invention, special considerations need to be made with interpolation when a categorical variable is mapped to color and a threshold is used to help reduce confusion and decrease processing time by summing all weights in the vector below the threshold and assigning to it a single neutral color (as previously described in reference to FIGS. 16 A and 16 B). An illustration of the special considerations is explained in reference to FIGS. 19 and 20 . In FIG. 19 , vectors 1910 and 1920 each represent a different bin of a categorical variable that has 21 different values. These values are represented by a through u. If the threshold is set at 6%, then vector 1910 contains 18 values with weights less than 6%. As described above, the present invention combines these weights and assigns a new value other. This is illustrated in vector 1930 . A similar process occurs for vector 1920 . Here. with the threshold again at 6%, vector 1920 contains 15 values with weights less than 6%. Once these weights are combined, vector 1920 becomes vector 1940 .

Referring again to vectors 1930 and 1940 , assume these two vectors need to be interpolated. A problem arises because the vectors have different values. Vector 1930 has values b, c, k and other. Vector 1940 has values b, j, k, l, n, r and other. To solve this problem, the present invention expands both vectors to include the same values. For each value a vector is expanded to include, a weight of zero is assigned to that value. This is illustrated in FIG. 20 . Once expanded, vector 1930 becomes vector 2010 and vector 1940 becomes vector 2020 .

Prior to interpolation, the data in vectors 2010 and 2020 need to be merged as described above in reference to Table 9. Using the same example as above (i.e., t 0.5 corresponding to a mid-point position between the second and third discrete positions on the slider scale), the merged data appears as illustrated in vector 2030 and vector 2040 . The interpolation of vector 2030 and vector 2040 is illustrated in vector 2050 . Specifically, (13 4.5)/(1.5) 11.7 for value b; (8 0)/(1.5) 5.3 for value c (0 3.5)/(1.5) 2.3 for value j; (21 5.5)/(1.5) 17.6 for value k; (0 4.5)/(1.5) 3 for value 1; (0 6.5)/(1.5) 4.3 for value n; (0 10.5)/(1.5) 7 for value r; and (58 15)/(1.5) 48.7 for value other. Note that the percentages (or weights) in vector 2050 add up to approximately 100 percentage after the interpolation.

The present invention may be implemented using hardware, software, firmware, or a combination thereof and may be implemented in a computer system or other processing system. In fact, in one embodiment, the invention is directed toward a computer system capable of carrying out the functionality described herein. For example, as shown in FIG. 11 , a binning module 1102 , as part of a computer graphics system 1100 , can be used in binning the data points into bins in step and determine a bin position for each bin (as described in step 120 of FIG. 1 ). A counter unit 1104 can be used to determine a count of scatter data points in each bin (as described in step 130 of FIG. 1 ). An interpolation module 1106 can be used to interpolate scatter data points corresponding to a given position between discrete positions of an external query device (not shown). In addition, interpolation module 1106 can be designed to perform steps 910 through 940 of FIGS. 9A and 9B in order to generate interpolated bins. A rendering unit 1108 can be used for rendering a data visualization representative of the interpolated bins (as described in step 150 of FIG. 9 ).

6. Example GUI Computer Environment

FIG. 5 is a block diagram illustrating an example environment in which the present invention can operate. The environment is a computer system 500 that includes one or more processors, such as processor 504 . Computer system 500 can include any type of general computer.

The processor 504 is connected to a communications bus 506 . Various software embodiments are described in terms of this example computer system. This description is illustrative and not intended to limit the present invention. After reading this description, it will be apparent to a person skilled in the relevant art how to implement the invention using other computer systems and/or computer architectures.

Computer system 500 includes a graphics subsystem 503 . Graphics subsystem 503 can be implemented as one or more processor chips. The graphics subsystem 503 can be included as part of processor 504 as shown in FIG. 5 or as a separate graphics engine or processor. Graphics data is output from the graphics subsystem 503 to the bus 506 . Display interface 505 forwards graphics data from the bus 506 for display on the display unit 506 .

Computer system 500 also includes a main memory 508 , preferably random access memory (RAM), and can also include a secondary memory 510 . The secondary memory 510 can include, for example, a hard disk drive 512 and/or a removable storage drive 514 , representing a floppy disk drive, a magnetic tape drive, an optical disk drive, etc. The removable storage drive 514 reads from and/or writes to a removable storage unit 518 in a well known manner. Removable storage unit 518 represents a floppy disk, magnetic tape, optical disk, etc., which is read by and written to by removable storage drive 514 . As will be appreciated, the removable storage unit 518 includes a computer usable storage medium having stored therein computer software and/or data.

In alternative embodiments, secondary memory 510 may include other similar means for allowing computer programs or other instructions to be loaded into computer system 500 . Such means can include, for example, a removable storage unit 522 and an interface 520 . Examples can include a program cartridge and cartridge interface (such as that found in video game devices), a removable memory chip (such as an EPROM, or PROM) and associated socket, and other removable storage units 522 and interfaces 520 which allow software and data to be transferred from the removable storage unit 522 to computer system 500 .

Computer system 500 can also include a communications interface 524 . Communications interface 524 allows software and data to be transferred between computer system 500 and external devices via communications path 526 . Examples of communications interface 524 can include a modem, a network interface (such as Ethernet card), a communications port, etc. software and data transferred via communications interface 524 are in the form of signals which can be electronic, electromagnetic, optical or other signals capable of being received by communications interface 524 , via communications path 526 . Note that communications interface 524 provides a means by which computer system 500 can interface to a network such as the Internet.

Graphical user interface module 530 transfers user inputs from peripheral devices 532 to bus 506 . These peripheral devices 532 can be a mouse, keyboard, touch screen, microphone, joystick, stylus, light pen, or any other type of peripheral unit. These peripheral devices 532 enable a user to operate and control the data visualization tool of the present invention as described above.

The present invention is described in terms of this example environment. Description in these terms is provided for convenience only. It is not intended that the invention be limited to application in this example environment. In fact, after reading the following description, it will become apparent to a person skilled in the relevant art how to implement the invention in alternative environments.

The present invention is preferably implemented using software running (that is, executing) in an environment similar to that described above with respect to FIG. 5 . In this document, the term computer pro(gram product is used to generally refer to removable storage unit 518 or a hard disk installed in hard disk drive 512 . These computer program products are means for providing software to computer system 500 .

Computer programs (also called computer control logic) are stored in main memory and/or secondary memory 510 . Computer programs can also be received via communications interface 524 . Such computer programs, when executed, enable the computer system 500 to perform the features of the present invention as discussed herein. In particular, the computer programs, when executed, enable the processor 504 to perform the features of the present invention. Accordingly, such computer programs represent controllers of the computer system 500 .

In an embodiment where the invention is implemented using software, the software may be stored in a computer program product and loaded into computer system 500 using removable storage drive 514 , hard drive 512 , or communications interface 524 . Alternatively, the computer program product may be downloaded to computer system 500 over communications path 526 . The control logic (software), when executed by the processor 504 , causes the processor 504 to perform the functions of the invention as described herein.

In another embodiment, the invention is implemented primarily in firmware and/or hardware using, for example, hardware components such as application specific integrated circuits (ASICs). Implementation of a hardware state machine so as to perform the functions described herein will be apparent to persons skilled in the relevant art(s).