Repository navigation
Progressive mode #2
Description
Activity
Update: It's not perfect, but it's been implemented.
https://github.com/kojix2/YouPlot#how-to-plot-real-time-dataReacted by gemmaroProgressive mode will work.
However, it can be very slow if there are many lines of data.
YouPlot reads one new line of data from the standard input and passes all the previous data to UnicodePlot. This slows down the behavior.
There are two solutions that come to mind right away.- One is to set the display interval. For example, you can wait until you receive 10 new rows of data before drawing the plot.
- Per lines
- lines
- Auto mode to make UnicodePlot benchmark measurements and take their reciprocals
- Per time
- Period or Frequency
- Per lines
- The other is to set the range. For example, you can choose to use only the last 100 data and not display the data before that.
I will consider the appropriate command line options.
Idea:- --interval SECOND
- --window
- One is to set the display interval. For example, you can wait until you receive 10 new rows of data before drawing the plot.
I thought this could be a nice way to try and make an alert count histogram using the line charting... but progressive mode keeps the previous values, right? I notice that if I feed it an array with 10 items, shift the first and add a new one, instead of updating it'll add the new set along with the previous ones, instead of rewriting the whole set.
ah, now I understand the idea for the
--windowoption, only the new item should be fed to it, and uplot itself would discard items over the window count. Can't wait to see if this ever comes to light =)

It may not be a very practical idea. But I would like to see a progressive mode. Some programs take a long time to run and gradually output the results to standard output. In that case, waiting until all the output is finished would take a long time. I'd like to have a mechanism to pass the results to the next pipeline before all the outputs are finished. However, I think it would be very difficult to create such a mechanism.