A2-JamesAndrews
From CS294-10 Visualization Fa07
Contents |
[edit] Domain
I'm interested in accuracy of typical user inputs, such as the mouse and tablet pen, for the purpose of drawing. So, for example, if you have a specific line you want to draw, I wonder how the line you actually draw with a mouse differs from the line you intended. Understanding this relationship may help a computer refine an 'MS paint' drawing via a stroking process, where the user re-draws over segments that do not satisfy them.
[edit] Questions
Question 1: Where and in what ways does error show up in a stroke?
Question 2: How does input device affect the error?
[edit] Data
I wrote a simple program to collect data. It draws random lines (one at a time), lets a user trace them, lets the user press Tab to get a new random line, and records what the user does. This took a bit of iteration, as when my data collector just gave the most 'fundamental' data (line segment parameters, mouse positions when drawing), I found it rather painful to start putting all my vector math into Spotfire's rather limiting calculation functionality. I also didn't see a nice way to extract 'per stroke' information from the data, though I gave each stroke a unique ID, since my rows were per point. Comparing my first program [1] to my final [2] (vec2.h is here: [3]), beyond bug fixes you can see that a lot of extra calculations were rolled in to the program.
I collected data for a touchpad, mouse, and tablet; I did not get any subjects to participate, so I'm the only user in this preliminary test.
[edit] Glossary
Because my names aren't the most intuitive, here are some statistics that I found useful in the analysis:
normXAlongStroke: The project of the drawn point on the intended line, with the endpoint that the stroke was closest to when started at 0 and the other end point at 1.
dist: The 'error' expressed as the distance of the drawn point to the desired line.
sideways: The component of distance error which is normal to the line segment.
beyondends: The extent to which the point is beyond the ends of the line.
lineAng and lineLen: The angle and length of the 'intended' line.
angleDiffDirectionless: The difference in direction (in radians) between the intended line and the mouse's latest direction (calc'd as current mouse pos minus previous mouse point)
[edit] Visualizations
Sanity check: Angle vs length of "target" lines
As a first step, I made sure my data covered a fairly even distribution of line angles and lengths for each input type.
Messy scatter plot: The distance error vs normXAlongStroke
Since my data really is a scattering of points I thought a good way to view it would be a scatter plot, but the density of these plots made it rather hard to extract information ... even when I make them as large as possible. I see some hints about the distribution of errors -- the touchpad appears to have the largest errors, and starting the line 'too early' appears more common for the tablet than the mouse, while continuing it 'too late' is more common than 'too early' (and more extreme!) for all input types. But the trends for the bulk of the stroke -- the shapeless mass of points in the middle -- are impossible to make out.
Brushing angle differences: Highlighting the points with large directional (angle) errors
Brushing the large angle differences in one plot reveals that directional errors (angle differences) are distributed to the start and end of mouse & tablet drawings, but more uniformly for the touchpad. Large direction errors don't seem to correlate well with any particular level of distance error.
Quirky data: Line angle vs direction error (angle difference)
One last scatter plot: This shows two strange properties of my data. First, the tablet didn't see any angles from 1 to 1.5 radians. I'm pretty sure this is just by random chance, but perhaps I need to take more data! Second, there are curious angled lines that appear in the same places for each plot; I'm not sure why that happens.
Moving on from scatter plots, the following line charts seem to give the clearest picture of how the different input devices give different lines.
Distance error along a line
We see here how the mouse gives the largest error at the end of strokes, while the touchpad goes the furthest beyond the intended endpoint.
Sideways error along a line -- same values as dist for x in [0,1]
The mouse and tablet have increasing error along the line (the tablet increasing more gradually), while the touchpad gives the most error in the middle. Touchpad points that go beyond the intended end of the line segment appear to stick closely to the line (the infinite extension of that segment).
Direction error along a line
Direction is least accurate near the ends of the line. The very last bit of direction for the touchpad is especially inaccurate; in overextended lines for the other devices, over-extensions have less error.
Distance to previous point (roughly speed) along a line
Speed increases in the middle of the line, and slows toward endpoints. I'm hesitant to compare raw speeds across devices without somehow normalizing them for the length of the intended line ...
The previous graph, column-trellis'd by length of the desired line
The ordering of max speed across devices isn't 100% consistent, but it's close to the touchpad, tablet, mouse ordering implied by the previous graph. For each device I do generally increase max speed with line length. At this level of splitting the data (binning for the trellis, then further binning on the X axis), deviations from the trends (such as the 3rd length-bin of the mouse, which shows relatively high speed) seem like they may just be noise.
Showing the data per bin: apparently we're still working with at least 100 points in the centers of the lines. The plot I mentioned before (3rd length bin for the mouse) seems to have as much data as anything, although the plot directly below it is a bit lacking.
On a related note, it may be interesting to examine the variances of some of the above line plots:
Not too surprising -- variances seem to correlate to error magnitudes. Perhaps notable deviations from this rule are the relatively apparently large variances for distance errors -- in particular for the tablet, towards the end. Also possibly of note is the touchpad's suddenly low variance in the angle/direction graph, but there are very few data points there so it makes some sense.
[edit] Conclusion
My questions were a bit vague, but I think through these visualizations I do have at least some understanding of the different errors that result from using these three different input devices for drawing lines. (Now I'd be interested to see how the data changes for curves, or for lines which are briefly displayed (not kept on the screen beneath the user's drawing), or as the user is shown an estimate of the intended line.)













