Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Downsample plugin for Flot charts.

NotificationsYou must be signed in to change notification settings

sveinn-steinarsson/flot-downsample

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

54 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This plugin forFlot charts downsamplesdata before rendering the chart. The purpose is to try retain thevisual characteristics of the original line using considerably fewer data points.The algorithm (calledLargest-Triangle-Three-Buckets orLTTB) used in this plugin is described in aMaster's thesis (seehdl.handle.net/1946/15343) in Computer Science by Sveinn Steinarssonat theUniversity of Iceland.The topic of the thesis is how todownsample time series for visual representationand was initially suggested byDataMarket.JavaScript optimization was done with the help ofBorgar Þorsteinsson.

Status

The Flot library is not commonly used nowadays, but the LTTB (Largest-Triangle-Three-Buckets) algorithm remains popular and is well-established for downsampling chart data.

For using LTTB in other libraries or frameworks, you can refer to theLTTB adapted for other programming languages or frameworks section.

Demo

Demo can viewed atbase.is/flot/.

Additional demo concerning chart resizing is also available atbase.is/flot/resize/

Usage

series:{downsample:{threshold:1000// 0 disables downsampling for this series.}}

Known limitations

  • Does not support gaps (null values) in the data array.
  • X-values must be in a strictly increasing order.

Articles related to the algorithm (LTTB)

The algorithm (LTTB) adapted for other programming languages or frameworks

Note: I have not tested all these versions and some might have different or additional features.

(Please let me know if you make your own port of the LTTB algorithm so I can list it here.)

License

flot-downsample is released under the terms ofthe MIT License.

About

Downsample plugin for Flot charts.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors10


[8]ページ先頭

©2009-2025 Movatter.jp