<< Chapter < Page | Chapter >> Page > |
The four classes that I will present and explain in this module are designed to make it easy for you to plot and examine large quantities of data.
The first class named PlotALot01 is designed for the plotting of large quantities of single-channel data. Figure 1 shows an example of the plotted output from this class when used to plot a small amount of data.
Figure 1. Sample output for PlotALot01 class. |
---|
To use the class named PlotALot01 to plot data, you first instantiate an object of the class, and then you feed data to it as the databecomes available within your program.
When all of the data has been fed to the plotting object, you call a method named plotData on the object. This causes the object to produce one or more pages of plotted data in a stack on the screen. The page containingthe earliest data is on the top of the stack and the page containing the latest data on the bottom of the stack.
The first data sample is plotted on the left end of the top trace on the top page (titled Page: 0) . Successive data values are plotted from left to right across the page. When the data for the first trace reaches the right endof the trace, the next data sample is plotted at the left end of a new trace that is created below the current trace. Hence, the chronological order of thedata is from left to right, top to bottom.
A horizontal axis is drawn for each trace. Positive data values are plotted above the axis and negative values are plotted below the axis.
When the bottom trace on a page is filled, a new page is created automatically. The next data sample is plotted on the left end of the top traceon the new page and the process described above is repeated until that page also become full. Then a new page is created, etc.
You can cause the page size to be as large as you want up to the full size of the screen on your computer. You can create as many pages as you want and youcan place as many traces on each page as you want.
Other than the amount of memory that is available to the Java virtual machine, (and perhaps some limit on the number of Page objects allowed by the operating system) , there is almost no limit to the number of pages that can be produced and the amount of data that can be plotted.
I have successfully plotted two million data values in 141 full screen pages on a modest laptop computer with no difficulty whatsoever. When I pushed thattotal up to eight million data values in 563 full screen pages, the plotting process slowed down, but I was still able to display and examine the plots. Thepractical limit on my computer seems to be somewhere between two million and eight million data values.
Figure 1 shows two pages that were physically removed from the stack and arranged with the page containing the earliest data above the page containingthe latest data for publication in this module.
Notification Switch
Would you like to follow the 'Digital signal processing - dsp' conversation and receive update notifications?