pond-ts API Reference (core)
Preparing search index...
LiveRollingAggregation
Class LiveRollingAggregation<S, Out>
Type Parameters
S
extends
SeriesSchema
Out
extends
SeriesSchema
=
SeriesSchema
Index
Constructors
constructor
Properties
name
schema
Accessors
length
window
Size
Methods
aggregate
at
cumulative
diff
dispose
fill
filter
map
on
pct
Change
rate
select
value
window
Constructors
constructor
new
LiveRollingAggregation
<
S
extends
SeriesSchema
,
Out
extends
SeriesSchema
=
SeriesSchema
,
>
(
source
:
LiveSource
<
S
>
,
window
:
RollingWindow
,
mapping
:
AggregateMap
<
S
>
,
)
:
LiveRollingAggregation
<
S
,
Out
>
Type Parameters
S
extends
SeriesSchema
Out
extends
SeriesSchema
=
SeriesSchema
Parameters
source
:
LiveSource
<
S
>
window
:
RollingWindow
mapping
:
AggregateMap
<
S
>
Returns
LiveRollingAggregation
<
S
,
Out
>
Properties
Readonly
name
name
:
string
Readonly
schema
schema
:
Out
Accessors
length
get
length
()
:
number
Returns
number
window
Size
get
windowSize
()
:
number
Returns
number
Methods
aggregate
aggregate
<
const
M
extends
Readonly
<
AggregateMapEntries
<
Out
>
>
>
(
sequence
:
Sequence
,
mapping
:
M
,
)
:
LiveAggregation
<
Out
>
Type Parameters
const
M
extends
Readonly
<
AggregateMapEntries
<
Out
>
>
Parameters
sequence
:
Sequence
mapping
:
M
Returns
LiveAggregation
<
Out
>
at
at
(
index
:
number
)
:
EventForSchema
<
Out
>
|
undefined
Parameters
index
:
number
Returns
EventForSchema
<
Out
>
|
undefined
cumulative
cumulative
<
const
Targets
extends
string
>
(
spec
:
{
[
K
in
string
]
:
|
"sum"
|
"count"
|
"min"
|
"max"
|
(
(
acc
:
number
,
value
:
number
)
=>
number
)
}
,
)
:
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Targets
>
,
]
,
>
Type Parameters
const
Targets
extends
string
Parameters
spec
:
{
[
K
in
string
]
:
|
"sum"
|
"count"
|
"min"
|
"max"
|
(
(
acc
:
number
,
value
:
number
)
=>
number
)
}
Returns
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Targets
>
,
]
,
>
diff
diff
<
const
Target
extends
string
>
(
columns
:
Target
|
readonly
Target
[]
,
options
?:
{
drop
?:
boolean
}
,
)
:
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
Type Parameters
const
Target
extends
string
Parameters
columns
:
Target
|
readonly
Target
[]
Optional
options
:
{
drop
?:
boolean
}
Returns
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
dispose
dispose
()
:
void
Returns
void
fill
fill
(
strategy
:
LiveFillStrategy
|
LiveFillMapping
<
Out
>
,
options
?:
{
limit
?:
number
}
,
)
:
LiveView
<
Out
>
Parameters
strategy
:
LiveFillStrategy
|
LiveFillMapping
<
Out
>
Optional
options
:
{
limit
?:
number
}
Returns
LiveView
<
Out
>
filter
filter
(
predicate
:
(
event
:
EventForSchema
<
Out
>
)
=>
boolean
)
:
LiveView
<
Out
>
Parameters
predicate
:
(
event
:
EventForSchema
<
Out
>
)
=>
boolean
Returns
LiveView
<
Out
>
map
map
(
fn
:
(
event
:
EventForSchema
<
Out
>
)
=>
EventForSchema
<
Out
>
)
:
LiveView
<
Out
>
Parameters
fn
:
(
event
:
EventForSchema
<
Out
>
)
=>
EventForSchema
<
Out
>
Returns
LiveView
<
Out
>
on
on
(
type
:
"event"
,
fn
:
EventListener
)
:
()
=>
void
Parameters
type
:
"event"
fn
:
EventListener
Returns
()
=>
void
on
(
type
:
"update"
,
fn
:
UpdateListener
)
:
this
Parameters
type
:
"update"
fn
:
UpdateListener
Returns
this
pct
Change
pctChange
<
const
Target
extends
string
>
(
columns
:
Target
|
readonly
Target
[]
,
options
?:
{
drop
?:
boolean
}
,
)
:
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
Type Parameters
const
Target
extends
string
Parameters
columns
:
Target
|
readonly
Target
[]
Optional
options
:
{
drop
?:
boolean
}
Returns
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
rate
rate
<
const
Target
extends
string
>
(
columns
:
Target
|
readonly
Target
[]
,
options
?:
{
drop
?:
boolean
}
,
)
:
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
Type Parameters
const
Target
extends
string
Parameters
columns
:
Target
|
readonly
Target
[]
Optional
options
:
{
drop
?:
boolean
}
Returns
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
select
select
<
const
Keys
extends
readonly
(
keyof
EventDataForSchema
<
Out
>
)
[]
>
(
...
keys
:
Keys
,
)
:
LiveView
<
readonly
[
Out
[
0
]
,
PickSelectedColumns
<
ValueColumnsForSchema
<
Out
>
,
Keys
[
number
]
>
,
]
,
>
Type Parameters
const
Keys
extends
readonly
(
keyof
EventDataForSchema
<
Out
>
)
[]
Parameters
...
keys
:
Keys
Returns
LiveView
<
readonly
[
Out
[
0
]
,
PickSelectedColumns
<
ValueColumnsForSchema
<
Out
>
,
Keys
[
number
]
>
,
]
,
>
value
value
()
:
Record
<
string
,
ColumnValue
|
undefined
>
Returns
Record
<
string
,
ColumnValue
|
undefined
>
window
window
(
size
:
RollingWindow
)
:
LiveView
<
Out
>
Parameters
size
:
RollingWindow
Returns
LiveView
<
Out
>
Settings
Member Visibility
Inherited
External
Theme
OS
Light
Dark
On This Page
Constructors
constructor
Properties
name
schema
Accessors
length
window
Size
Methods
aggregate
at
cumulative
diff
dispose
fill
filter
map
on
pct
Change
rate
select
value
window
pond-ts API Reference (core)
Loading...