Errata

Practical Time Series Analysis

Errata for Practical Time Series Analysis

Submit your own errata for this product.

The errata list is a list of errors and their corrections that were found after the product was released. If the error was corrected in a later version or reprint the date of the correction will be displayed in the column titled "Date Corrected".

The following errata were submitted by our customers and approved as valid errors by the author or editor.

Color key: Serious technical mistake Minor technical mistake Language or formatting error Typo Question Note Update

Version Location Description Submitted By Date submitted Date corrected
ePub
Page unknown
Chapter 2. -> Cleaning Your Data -> Smoothing Data -> Exponential smoothing

There is an extra semicolon in the first formula that states: “Smoothed value at time t".
It should be "S_t = d x S_{t-1}" instead of "S_t = d x ; S_{t-1}"

Note from the Author or Editor:
You are correct. This semicolon is a typo. Thank you for reporting this!

Anonymous  Feb 20, 2020 
Printed
Page 12
Code Line 7

Running the notebook example found on the respective GitHub post for the first simulation example throws an error with regards to the dtype comparison user_rng = rng[rng > join_date]
Error is raised because command is trying to compare a Timestamp object with a period[W_SUN) object.

However, have found adding the following allows the code to proceed.
user_rng = rng[rng.start_time > join_date]

Note from the Author or Editor:
Please change the code in the book as the submitter has recommended. I have updated the Github repository to reflect this.

Murray M. Gillin  Dec 15, 2020 
Page 13
"More Resources" section, line 3:

420-24
->
420-424

Note from the Author or Editor:
ok happy to adopt this chang.

Ryoko  Jul 24, 2021 
Page 14
line2, line 7, line 13

Some of the numbers on the reference page are missing.

line2:
267-98
->
267-298

line7:
451-68
->
451-468

line13:
443-73
->
443-473

Note from the Author or Editor:
Please adopt suggested changes.

Ryoko  Jul 24, 2021 
Page 34
Numbered bullets at the bottom of the page

I don't understand the difference between item 2. and item 4.
It seems that they are saying the same thing.

> 2. Understand how we can avoid lookahead by not using data for
> timestamps that produce the data’s availability.

> 4. Avoid lookahead by not using data for timestamps that produce
> information we shouldn’t yet know about.

Note from the Author or Editor:
You are right- these seem completely redundant. Please delete item # 2 because the wording for item # 4 is clearer.

Ryoko  Jul 24, 2021 
Printed
Page 58
python code

The issue is from using Pandas version 1.0.0. It's probably been pointed out already. I haven't seen any comments on this, so I thought I should point it out.

The code has written out

air['Smooth.5'] = pd.ewma(air, alpha = .5).Passengers
air['Smooth.1'] = pd.ewma(air, alpha = .1).Passengers
air['Smooth.9'] = pd.ewma(air, alpha = .9).Passengers

It looks like pandas changed ewma to ewm and it seems to be a function of the dataframe.

The code below appears to work

air['Smooth.5'] = air.ewm(alpha=0.5).mean().Passengers
air['Smooth.1'] = air.ewm(alpha=0.1,).mean().Passengers
air['Smooth.9'] = air.ewm(alpha=0.9,).mean().Passengers

https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.ewm.html?highlight=ewma

https://pandas.pydata.org/pandas-docs/stable/user_guide/computation.html#exponentially-weighted-windows


Note from the Author or Editor:
The submitter is correct, and the code should be updated exactly as indicated in the erratum submission.

Mark Wilson  May 18, 2020 
Printed
Page 90
Figure 3-8

While reading the chapter 3 of your book, I think I found a mistake from the description of Figure 3-8.

It says
Figure 3-8. An expanding window “max” (long dashes) and an expanding window “mean” (short dashes). Use of an expanding window means that the max always reflects the global max up until that time, making it a monotonic function. Thanks to the long “memory” of the expanding window, the expanding window mean is lower than the rolling mean (Figure 3-7) because the underlying trend is less prominent in the expanding mean. Whether this is good, bad, or neutral depends on our assumptions and knowledge of the underlying system.

In the middle of the description, you referred "Figure 3-7" as the rolling mean. However, Figure 3-7 is about rolling window minimum.

I think this should be corrected as Figure 3-6 instead of 3-7.

Anonymous  Apr 17, 2020 
Printed
Page 169
2nd line

Says: We begin by substituting the value of phi_0, which we can derive Equation 6-4 frim Equation 6-3

this is not grammatical

Note from the Author or Editor:
" which we can derive Equation 6-4 frim Equation 6-3" is wrong. Instead we should use "which we can derive from Equation 6-3".

Loren Trigo  Dec 28, 2019 
Printed
Page 197
3rd equation

the subscripts for the third equation:
Actual: y_(1,t)
Should be: y_(3_t)

Note from the Author or Editor:
The submission already indicates exactly what should be changed, however I am so far unable to confirm because my available copy of the book does not seem to include this error on this page. Would someone at O'Reilly be able to send me a photo of this page in the printed book? (I am traveling for several weeks and will not have access to a printed copy of the book). Thank you!

Loren Trigo  Dec 28, 2019 
Printed
Page 213
4th paragraph

"In Figure 7.2" should be "In Figure 7.1".

Note from the Author or Editor:
Thank you for your careful reading. You are absolutely right!

Bruno Costa  Mar 10, 2020 
PDF
Page 213
R code

It should be

plot(a, main = "Acceleration", type = 'l')

Instead of

plot(acceleration, main = "Acceleration", type = 'l')

Note from the Author or Editor:
Please adopt this requested change. (I have adopted in Atlas)

Andres Mora  Dec 04, 2020 
Page 256
Line 8 from the bottom

Some of the numbers on the reference page are missing.
72-7
->
72-77

Note from the Author or Editor:
Sure, happy to adopt this change.

Ryoko  Jul 24, 2021 
Printed
Page 307
bottom

" So for example, we would train three batches at once on the following sequence of numbers"

This is confusing language and should be replaced with the following:

Begin a new paragraph: "Consider the following sequence of numbers ordered from left to right and top to bottom. (The bold is to help the reader find some of the starting values in the series delineated below in the TNC and NTC formats and does not otherwise have significance.)"

Note from the Author or Editor:
The author filed this erratum after a translator pointed out the ambiguous language.

Anonymous  Jul 09, 2020 
PDF
Page 307
middle of page

Confusing/misleading sentence: "This could be joined to the labels we produced for Y like so:"

Replace with:
"The data we prepared in NTC format above has the corresponding labels indicated below. Also remember that the time labels on the side represent which sample, of the N samples in a batch, is in that row, so the row label "t-1" is indicating that this is the sample prepared for a y measured at t-1."

Note from the Author or Editor:
The author filed this erratum after a translator pointed out the ambiguous language.

Anonymous  Jul 09, 2020