aggregates

package
v1.8.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 20, 2024 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Reduce

func Reduce(metrics []string) func(*Stats, map[string]any)

func StatToValue

func StatToValue(metric string) func(s *Stats) float64

Types

type Stats

type Stats struct {
	Visitors       float64
	Visits         float64
	PageViews      float64
	ViewsPerVisits float64
	BounceRate     float64
	VisitDuration  float64
	Events         float64
	// contains filtered or unexported fields
}

func Aggregates

func Aggregates(ctx context.Context, ts *timeseries.Timeseries, domain string, start, end time.Time, interval query.Interval, filters query.Filters, metrics []string) *Stats

func (*Stats) Compute

func (s *Stats) Compute()

func (*Stats) Read

func (d *Stats) Read(cu *cursor.Cursor, f models.Field, view, shard uint64, match *ro2.Bitmap) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL