Skip to content

Display Most Recent Rolling Average #2161

Answered by Fil
timbomckay asked this question in Q&A
Discussion options

You must be logged in to vote

Plot.windowY({k: 28, anchor, strict, ...options}) is a shorthand notation for:

Plot.map({y: Plot.window({ k: 28, anchor, strict })}, options)

which you can apply to multiple channels like so:

Plot.map({
  text: Plot.window({ k: 28, anchor, strict }),
  y: Plot.window({ k: 28, anchor, strict })
}, options)

See https://observablehq.com/plot/transforms/window

(You can also define window = Plot.window({ k: 28, anchor, strict }) and write Plot.map({text: window, y: window}, options))

Replies: 1 comment 4 replies

Comment options

Fil
Sep 4, 2024
Collaborator

You must be logged in to vote
4 replies
@timbomckay
Comment options

@timbomckay
Comment options

@Fil
Comment options

Fil Oct 3, 2024
Collaborator

@timbomckay
Comment options

Answer selected by Fil
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants