Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Getting Started with Haskell Data Analysis

You're reading from   Getting Started with Haskell Data Analysis Put your data analysis techniques to work and generate publication-ready visualizations

Arrow left icon
Product type Paperback
Published in Oct 2018
Publisher Packt
ISBN-13 9781789802863
Length 160 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
James Church James Church
Author Profile Icon James Church
James Church
Arrow right icon
View More author details
Toc

Plotting a moving average

We're going to be expanding on our knowledge of average by introducing the moving average. The moving average is simply the average of a subset of the data, where we have a small window in which we compute the average and then we move that window, and then we compute the average again. We keep repeating this until we've expended our data. So, in this section, we're going to take a look at creating line plots. We're going to introduce the moving average, and then we're going to plot a moving average. Let's go back to our notebook and continue from where we left off.

In the last section, the plot that we saw had a lot of + signs, and that doesn't make for an elegant graph. So, what we're going to do is to use a line plot, as demonstrated in the following example:

Now, Data2D is the formal way of introducing data...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image