mavg_plot | R Documentation |
Constructs a moving average plot of a binary sequence.
mavg_plot(y, width=20)
y |
vector of 0's and 1's |
width |
size of the window for the moving average |
Jim Albert
Albert, J. (2013), Looking at Spacings to Access Streakiness, Journal of Quantitative Analysis of Sports, Vol 9, Issue 2, 151-163.
y <- rbinom(500, size=1, prob=0.3) mavg_plot(y, width=20)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.