package rdp
import "github.com/influxdata/flux/stdlib/experimental/polyline/rdp"
Index ¶
- func DownSampleRetention(ipdata []Point, startIndex int64, endIndex int64, weights []float64) []float64
- func FindFarthestPoint(line ConnectLine, ipdata []Point) (farthestPointIndex int, farthestPointDistanceFromLine float64)
- type ConnectLine
- type Point
- func DownSampleIpdata(ipdata []Point, epsilon float64) []Point
- func DownSampleIpdataAuto(ipdata []Point) []Point
- type Rdp
- func New(timeColumn string, valColumn string, threshold float64, retentionPercent float64, alloc memory.Allocator) *Rdp
- func (r *Rdp) Do(vs *array.Float, ts *array.Float) (*array.Int, *array.Float, error)
- func (r *Rdp) SplitCoordinates(sampledPoints []Point) (*array.Int, *array.Float)
- func (r *Rdp) ToPoints() []Point
Functions ¶
func DownSampleRetention ¶
func DownSampleRetention(ipdata []Point, startIndex int64, endIndex int64, weights []float64) []float64
func FindFarthestPoint ¶
func FindFarthestPoint(line ConnectLine, ipdata []Point) (farthestPointIndex int, farthestPointDistanceFromLine float64)
Types ¶
type ConnectLine ¶
func (ConnectLine) Coefficients ¶
func (l ConnectLine) Coefficients() (a, b, c float64)
type Point ¶
type Point struct {
// contains filtered or unexported fields
}
func DownSampleIpdata ¶
func DownSampleIpdataAuto ¶
type Rdp ¶
type Rdp struct {
// contains filtered or unexported fields
}
func New ¶
func New(timeColumn string, valColumn string, threshold float64, retentionPercent float64, alloc memory.Allocator) *Rdp
func (*Rdp) Do ¶
func (*Rdp) SplitCoordinates ¶
func (*Rdp) ToPoints ¶
Source Files ¶
- Version
- v0.196.1 (latest)
- Published
- Feb 19, 2025
- Platform
- linux/amd64
- Imports
- 6 packages
- Last checked
- 1 day ago –
Tools for package owners.