Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Machine Learning for Time-Series with Python
Machine Learning for Time-Series with Python

Machine Learning for Time-Series with Python: Use Python to forecast, predict, and detect anomalies with state-of-the-art machine learning methods , Second Edition

Arrow left icon
Profile Icon Ben Auffarth
Arrow right icon
Early Access Early Access Publishing in Apr 2026
$49.99
Full star icon Full star icon Half star icon Empty star icon Empty star icon 2.5 (2 Ratings)
Paperback Apr 2026 397 pages 2nd Edition
eBook
$35.98 $39.99
Paperback
$49.99
Subscription
Free Trial
Renews at $19.99p/m
Arrow left icon
Profile Icon Ben Auffarth
Arrow right icon
Early Access Early Access Publishing in Apr 2026
$49.99
Full star icon Full star icon Half star icon Empty star icon Empty star icon 2.5 (2 Ratings)
Paperback Apr 2026 397 pages 2nd Edition
eBook
$35.98 $39.99
Paperback
$49.99
Subscription
Free Trial
Renews at $19.99p/m
eBook
$35.98 $39.99
Paperback
$49.99
Subscription
Free Trial
Renews at $19.99p/m

What do you get with Print?

Product feature icon Instant access to your digital copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Redeem a companion digital copy on all Print orders
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Shipping Address

Billing Address

Shipping Methods
Table of content icon View table of contents Preview book icon Preview Book

Machine Learning for Time-Series with Python

Join our book community on Discord

https://packt.link/EarlyAccessCommunityQr code Description automatically generatedTime series problems are very important in the industry and academia. Many commercial applications use time series data, such as stock market analysis and predicting consumer behavior in retail. Time series data is used extensively in weather forecasting, stock market prediction, demand forecasting, and many more applications.The landscape in machine learning for time series has been changing and many different libraries and algorithms are out there to deal with time series. Some popular methods for time series include ARIMA, LSTM, Prophet, and SARIMA. This book is trying to help choose the right tools and approaches for specific situations.In this chapter, we'll discuss time series and the typical set of problems associated with them in more detail. After reading this chapter, you should become familiar with the following:

  • What is a time series?
  • Which sets of techniques are there for time series?
  • What are the different technical problems associated with time series?
  • What are the sets of techniques and approaches for time series?
  • How can we approach time series problems?

We'll conclude with a discussion of some historical development of time series and of the challenges and future directions in time series data analysis.

What is a time series?

A time series is a sequence of data points, typically measured at successive times, spaced at uniform time intervals. Time Series mostly come as discrete-time, where the time difference between each point is the same.Many disciplines, such as finance, public administration, energy, retail, and healthcare, are dominated by time series data. Large areas of micro- and macroeconomics rely on applied statistics with an emphasis on time series analyses and modeling.The following are examples of time series data:

  • Daily closing values of a stock index
  • Number of weekly infections of a disease
  • Weekly series of train accidents
  • Rainfall per day
  • Sensor data such as temperature measurements per hour
  • Population growth per year
  • Quarterly earnings of a company over a number of years
  • The number of views or visitors to a website over time

This is only to name but a few. Loosely speaking, any data that deals with changes over time is a time series. Since this is a book about time series data, it’s worth defining more formally what is considered a time series.Definition: Time Series are datasets where observations are arranged in chronological order.This is a very broad definition. Alternatively, we could have said that a time series is a sequence of data points taken sequentially over time, or that a time series is the result of a stochastic process.Formally, we can define a time series in two ways. The first one is as a mapping from the time domain to the domain of real numbers:

Where and .Another way to define a time series is as a stochastic process:

Here, X(t) or Xt denotes the value of the random variable X at time point t.If T is a set of real numbers, it's a continuous-time stochastic process. If T is a set of integers, we call it a stochastic process in discrete time. The convention in the latter case is to write {Xn}.Since time is the primary index of the dataset, by implication, time series datasets describe how the world changes over time. They often deal with the question of how the past influences the presence or future.The increase of monitoring and data collection brings with it the need for both statistical and machine learning techniques applied to time series to predict and characterize the behavior of complex systems or components within a system. An important part of working with time series is the question of how the future can be predicted based on the past. This is called forecasting.Some methods allow adding business cycles or other descriptors as additional features. These additional features are called exogenous features - they are time-dependent, explanatory variables. We'll go through examples of feature generation in Chapter 4, Machine Learning for Time Series.

Characteristics of time series

There are many different types of time series data, such as financial data, economic data, weather data, and social media data. Each type of data has its own challenges and requires its own methods for time series analysis and forecasting.Financial data is often non-stationary, meaning that the statistical properties of the data change over time. This makes it difficult to build models that can accurately predict future values. Economic data is often seasonal, meaning that there is a regular pattern of ups and downs over the course of a year. This can be difficult to model, as the seasonality may be caused by factors that are not easily observed or measured. Weather data is often chaotic, meaning that it is very difficult to predict even short-term future values. Social media data is often volatile, meaning that it can change rapidly and unexpectedly. This makes it difficult to build models that can accurately predict future values.One of the most common examples of time series data is stock prices. Stock prices are constantly changing, and they can be used to describe how a company is doing over time. Another example of time series data is weather data. Weather data can be used to describe changes in the weather over time, and it can be used to predict future weather patterns. A time series can be univariate, where there's one value against time, for example temperatures over time in London, United Kingdom. Such a time series can be represented using a line chart, where the x-axis is the time and the y-axis is the value of the time series. Time series can be multivariate as well. In this case, there are more than one variables that vary with time.Here's an extract of a time series dataset as an example, exported from Google Trends, on searches for Python, R, and Julia:

Figure 1.1: Extract of a time series dataset

This is a multivariate time series, with columns for Python, R, and Julia. The first column is the index, a date column, and its period is the month. In cases, where we have only a single variable, we speak of a univariate series. This dataset would be univariate if we had only one programming language instead of three.For many applications, it is useful to split a time series into its component parts, such as trend, seasonality, and noise.A trend is the general direction in which something is developing or changing, such as a long-term increase or decrease in a sequence. An example of where a trend can be observed would be global warming, the process by which the temperatures on our planet have been rising over the last half-century.Here's a plot of global surface temperature changes over the last 100 years from the GISS Surface Temperature Analysis dataset released by NASA:

Figure 1.2: GISS surface temperature analysis from 1880 to 2019

As you can see in Figure 1.2, temperature changes have been varying around 0 until the mid-20th century; however, since then, there's been a clearly visible trend of an overall rise in the yearly temperature.Seasonality is a variation that occurs at specific regular intervals of less than a year. Seasonality can occur on different time spans, such as daily, weekly, monthly, or yearly. An example of weekly seasonality would be sales of ice cream picking up each weekend. Also, depending on where you live, ice cream might only be sold in spring and summer. This is a yearly variation.Other than seasonal changes and trends, there is variability that's not of a fixed frequency or that rises and falls in a way that's not based on seasonal frequency. Some of these we might be able to explain based on the knowledge we have.As an example of cyclic variability that's irregular, bank holidays can fall on different calendar days each year, and promotional campaigns could depend on business decisions, such as the introduction of a new product.In electroencephalography (EEG), the electrical activity of the brain is recorded through electrodes placed on the scalp. Its signal typically shows strong oscillations (also referred to as brain waves) at a variety of frequency ranges. Here's a graph of an EEG signal (from the EEG Eye State dataset uploaded by Oliver Roesler from DHBW, Germany):

Figure 1.7: EEG signal

Such changes at the scale of seconds or milliseconds would not be called seasonal effects. Other changes that take place over time periods longer than a year would not be called seasonal either.The task of identifying, quantifying, and decomposing these and other characteristics is called time series analysis. Exploratory time series analysis is often the first step before any feature transformation and machine learning.

Which sets of techniques are there for time series?

There are many different techniques that can be used for each of these problem scenarios. In this book, we'll discuss the most popular methods for analyzing time series data, including traditional statistical methods, machine learning methods, and deep learning methods.Problems such as clustering, and classification/regression are generic to machine learning, signal processing, or statistical methods. Often, being aware of this can help establish a context for problem solving and allows one to draw from the broader set of methods within these areas.How is machine learning for time series similar or different from other ML disciplines? There are quite a few challenges specific to machine-learning with time series:

  • The main difference to - more generally - machine learning methods on tabular data is that the data is that the data are indexed by time. The temporal ordering of the data points is often important for the task at hand. This means that the data must be processed in a specific order and cannot simply be shuffled as is often done in machine learning on tabular data.
  • Time series data is often non-stationary, meaning that the statistical properties of the data change over time. This makes it difficult to build models that can generalize from the training data to the test data.

Machine learning has evolved as a powerful method for understanding hidden complexity in time series data. Recently, probabilistic models for time series such as Facebook Prophet, Markov models, or even fuzzy models, and counter-factual causal models such as Bayesian structural time series models as proposed by Google have gained in popularity. At the same time, multivariate forecasting has found practical use in multivariate multistep forecasts of energy demand with deep learning models. Finally, time series techniques such as bandit algorithms and Deep Q-Learning have found their applications in recommender systems and trading algorithms.Some models are adaptive or robust to certain kinds of drift. For example, ARIMA models are generally robust to small amounts of additive and multiplicative drift. The Random Forest algorithm, on the other hand, can be more robust under these conditions and does not require a fundamental update of the algorithm for each instance. Adaptive algorithms include effective resampling methods and adaptive operators that can cope with different types of concept drifts without complex optimizations for different data sets. Unfortunately, there are no hard and fast rules and you should experiment with both types of methods to see which works best for your data.The most prominent time series data technique is forecasting - the task to predict future values of the series. This can be done using methods such as ARIMA or many others, each coming with their own set of assumptions, drawbacks, and advantages.

What are the technical problems associated with time series?

The three main machine learning problems with time series are forecasting, classification, regression, and anomaly detection. In this section, we'll provide a broad overview of applications of time series and a history of machine learning and analysis techniques applied to time series.Common problem scenarios when dealing with time series data include:

  • Forecasting: The use of a model to predict future values based on previously observed values. This technique is used to predict future values of the time series based on past values. This can be done using methods such as ARIMA or exponential smoothing.
  • Decomposition: This technique is used to separate the data into its constituent parts such as trend, seasonality, and residuals. This can be done using methods such as additive or multiplicative decomposition. This involves trend analysis, where we identify long-term trends in a time series, and seasonality analysis, which is about identifying repeating patterns in a time series.
  • Classification/Regression: This technique is used to predict a target variable based on the time series data. This can be done using methods such as support vector machines or logistic regression.
  • Anomaly detection: Identifying unusual patterns (outliers) in a time series. Outliers are unusual observations that fall outside of the typical pattern.
  • Clustering: This technique is used to group together similar time series. This can be done using methods such as k-means clustering.
  • Drift detection: This technique is used to identify systematic changes in the time series data. This can be done using methods such as the Mann-Kendall test.
  • Smoothing: This technique is used to remove the noise from the data. This can be done using a simple moving average or a more sophisticated technique such as exponential smoothing.

An example for forecasting is ARIMA modeling, where we are using autoregressive and moving average models to forecast future values in a time series. Which technique you use will depend on the nature of your data and the problem you are trying to solve.Multivariate forecasting is a natural extension of the univariate case, where the goal is to predict multiple variables simultaneously. For example, in a company, one might want to forecast sales, price, inventory, and production simultaneously. This can be done with a vector autoregression model, where each variable is predicted as a function of its own past values and the past values of the other variables. Multistep forecasting is a generalization of the univariate case, where the goal is to predict multiple steps into the future. For example, in a company, one might want to forecast sales for the next 6 months. This can be done with a vector autoregression model, where each variable is predicted as a function of its own past values and the past values of the other variables.

How can we approach time series problems?

Given a time series problem, there is no one-size-fits-all approach - as it depends on the specific problem that you are trying to solve. In fact, there are many different approaches and ways to solve problems. The choice of method will depend on the type of data, the nature of the problem, and the desired outcome. However, there is a set of problem solving techniques that can help guide you approach any time series problem.Time series analysis (TSA) comprises methods for analyzing time series data in order to extract meaningful statistics and other characteristics of the data. Importing the data can be considered prior to time series analysis, and data cleaning, feature engineering, and training a machine learning model are not strictly part of time series analysis. We'll discuss TSA in chapter 2, Time-Series Analysis.The steps belonging to TSA and leading to preprocessing (feature engineering) and machine learning are highly iterative, and can be visually appreciated in the following time series machine learning flywheel:

Figure 2.1: The time-series machine learning flywheel

This flywheel emphasizes the iterative nature of the work. For example, data cleaning comes often after loading the data, but will come up again after we've made another discovery about our variables. I've highlighted TSA in dark, while steps that are not strictly part of TSA are grayed out.In summary, we have these steps:

  1. Define the problem: Is it a classification or regression problem? What are the inputs and outputs? What are the steps involved in solving the problem?
  2. Data Exploration: This step involves visualizing the data to understand the trends and patterns. This helps in developing the intuition for building the machine learning model.
  3. Preprocess the data: This step involves cleaning the data, dealing with missing values, and transforming the data so that it can be used by the machine learning algorithm. This step is crucial and includes feature engineering, scaling, normalization.
  4. Decompose the time series: This step is useful in understanding the trend, seasonality, and noise in the data. This step is necessary for certain kinds of methods, but not with others.
  5. Build models: Once the data is preprocessed, you can build models using traditional machine learning algorithms or time series specific algorithms.
  6. Evaluate the models: This step includes comparing the performance of different models and choosing the best one. It involves assessing the performance of the machine learning model on unseen data. This helps in fine-tuning the model and making it ready for deployment.
  7. Make predictions: This step involves using the final model to make predictions on new data.

There are many ways to deal with time series. Let's briefly go through the main categories of approaches, traditional time series methods, machine learning, and deep learning. All of them can be used for problems such as forecasting, classification and regression.Traditional time series methods are the most common approach to dealing with time series data. They involve using statistical methods to model the data and make predictions. They are simple and easy to interpret. A downside is that many of them assume that the data is stationary.Machine Learning methods can be applied to data that is not stationary. The downside is that applications can be more complex and results more difficult to understand.Deep learning is a branch of machine learning that uses neural networks to learn from data. These neural networks often have many parameters giving the model the potential to capture a wide range of phenomena, but require a lot of data to tune, and often predictions can be highly variable.To summarize: the best approach depends on the data, the problem, and the resources available.

Historical Development of Time Series Applications

An early work in time series analysis was The Art of Statistics, published in 1833 by Adolphe Quetelet. The first general work on time series analysis is generally credited to Francis Galton and his work Natural Inheritance, published in 1889. A significant contribution to the development of time series analysis was made by the statistician and biologist Ronald Fisher in his work Statistical Methods for Research Workers, published in 1925.Classical time series modeling approaches were introduced by George Box and Gwilym Jenkins in 1970 in their book "Time-Series Analysis Forecasting and Control." Most importantly, they formalized the ARIMA and ARMAX models and described how to apply them to time series forecasting. We'll talk about these types of models in Chapter 5, Forecasting with Moving Averages and Autoregressive Models.The study of time series in different scientific disciplines was foundational to fields such as demography, astronomy, medicine, and economics. We won't cover all these fields, but just give a few highlights, especially from astronomy and meteorology, which are particularly interesting cases for their development.

Astronomy

Observations of comets and asteroids, and the and the movements of the sun and the planets have been recorded for a long time, and people have been studying these records to understand the regularities and relationships of these movements and our place in the universe. For example, the Greek historian Herodotus wrote about the effects of the solar eclipse on the battle of Halicarnassus.One of the first modern scientific prediction of the future was made by Isaac Newton in a letter to Richard Bentley, who later published it in 1693 as A Letter of Mr. Isaac Newton, Containing his Natural Philosophy: Together with Translations from the Original Latin and French Versions; and a Commentary on his Work, Philosophiae Naturalis Principia Mathematica. In the letter, Newton predicts that the end of the world will take place in 2060.In the first paragraph of the letter, Newton correctly identifies five major problems in physics: motion, light, heat, magnetism, and gravity. He also correctly states that they can all be explained by the same principles. He goes on to say that the principles can be discovered by induction, which is the process of generalizing from specific observations to a general law. In the second paragraph, Newton states that the laws of motion can be used to predict the future, and that the future can be predicted with great accuracy. He then gives an example of this, predicting that the end of the world will take place in 2060.Although Newton's prediction was not accurate, it did demonstrate the potential of using scientific methods to understand the world around us and making predictions.Not much after Newton, in 1801, Carl Friedrich Gauss devised a method for determining the orbit of the dwarf planet Ceres. Ceres orbits in the asteroid belt between Mars and Jupiter. The German polymath's method was based on observations of a Catholic priest and astronomer, Giuseppe Piazzi, who traced an object between January and February 1801. Gauss then applied his method to the observations and used the results to predict where Ceres would be located on December 31, 1801. Ceres was discovered on the predicted date and location.Many discoveries in astronomy have been made recently. In 1978, an American astronomer, James Christy, discovered Pluto's largest moon. Christy used the U.S. Naval Observatory's telescope in Flagstaff, Arizona, to make the discovery. Time series images of Pluto showed that the dwarf planet's brightness varied by about 0.1% over a 6.4-hour period. This suggested that an object half the size of Pluto was orbiting it. Christy named the new object "Charon'' after the boatman who ferries souls across the River Styx in Greek mythology. Michael Brown and Chad Trujillo used similar techniques to discover a faint object beyond Neptune that they named Eris, today classified as a dwarf planet.New discoveries of dwarf planets and exoplanets are being made every year using new instruments and statistical approaches.

Meteorology

The modern science of meteorology has its roots in ancient times as well. The Babylonians are thought to have had some rudimentary knowledge about atmospheric processes, and they are known to have observed and recorded the regular ebb and flow of the tides.The Greek philosopher Aristotle was one of the first to write about weather and its measurement; however, it took much longer for the first weather predictions to be made. Vice Admiral Robert FitzRoy founded the United Kingdom's national weather service, the Meteorological Office, in 1854. FitzRoy had already reserved his place in history as the captain of the HMS Beagle, the ship that carried a recently graduated naturalist by the name of Charles Darwin around the world. It was FitzRoy, in fact, who coined the word forecast, although at the time, many contemporaries referred to them as "quack weather prognostications".The first computerized weather models were programmed on the Electronic Numerical Integrator and Computer (ENIAC). The ENIAC, designed by John Mauchly and J. Presper Eckert, could run arbitrary sequences of operations; however, it didn't read the programs from tapes but from plugboard switches. The giant 15x9-meter machine is exhibited today at the Smithsonian Institute in Washington, D.C. Consisting of 17,500 vacuum tubes, it first produced calculations for the construction of a hydrogen bomb and was then exploited to extend forecasting past one or two days using new methods of numerical weather prediction. The computer was programmed by Klara von Neumann.Here's a photo of the ENIAC (source: Wikimedia Commons):

Figure 1.6: Electronic Numerical Integrator and Computer (ENIAC)

You can see Betty Snyder, one of the earliest programmers of the ENIAC, standing in front of the ENIAC.Later, Joseph Smagorinsky and Douglas Lilly developed a mathematical model for turbulence used in computational fluid dynamics. This model, the Smagorinsky-Lilly model, which is still in use today, used data about the wind, cloud cover, precipitation, atmospheric pressure, and radiation emanating from the earth and sun as input. Smagorinsky continued to lead research on global warming, investigating the climate's sensitivity to increasing carbon dioxide levels.The introduction of mobile sensor arrays and computerized models has greatly increased the accuracy of weather predictions. Valuable temperature and wind data is collected by sensors deployed by meteorology offices or other sources, most importantly by commercial aircraft as they fly. Today, within a seven-day window, a forecast is accurate about 80% of the time. The grounding of commercial flights during the COVID pandemic, where there were about 75% fewer flights for some periods, has led to less accurate forecasts recently.DeepMind, a Google subsidiary, is working on artificial intelligence (AI) models to predict the weather. The technology could improve the accuracy of predictions by up to 50%.DeepMind’s AI model uses a neural network architecture called a recurrent neural network (RNN). It takes advantage of the fact that the weather depends on past weather patterns. A deep learning algorithm is trained on historical data to predict the weather. DeepMind’s AI model is able to predict weather patterns over a five-day period. The neural network is trained on 30 years of weather data from the United States’ Global Forecast System (GFS) weather model.

Summary

In this chapter, we’ve started with a definition of time series and its main properties. We gave examples for time-series and their basic characteristics. Further, we went through different kinds of problems such as forecasting, regression, classification, anomaly detection, and other types of analyses relevant to machine learning and statistics. Finally, we’ve tried to give a broad overview of applications of time series and a history of time series applications in astronomy and meteorology.In the next chapter, we'll look at time series analysis with Python.

Left arrow icon Right arrow icon

Key benefits

  • Explore popular and state-of-the-art machine learning methods, including the latest online and deep learning algorithms
  • Learn to increase the accuracy of your predictions by matching the right model to your problem
  • Master time series in Python via real-world case studies on operations management, digital marketing, finance, and healthcare

Description

The Python time-series ecosystem is a huge and challenging topic to tackle, especially for time series since there are so many new libraries and models. Machine Learning for Time Series, Second Edition, aims to deepen your understanding of time series by providing a comprehensive overview of popular Python time-series packages and helping you build better predictive systems. This fully updated second edition starts by re-introducing the basics of time series and then helps you get to grips with traditional autoregressive models as well as modern non-parametric models. By observing practical examples and the theory behind them, you will gain a deeper understanding of loading time-series datasets from any source and a variety of models, such as deep learning recurrent neural networks, causal convolutional network models, and gradient boosting with feature engineering. This book will also help you choose the right model for the right problem by explaining the theory behind several useful models. New updates include a chapter on forecasting and extracting signals on financial markets and case studies with relevant examples from operations management, digital marketing, and healthcare. By the end of this book, you should feel at home with effectively analyzing and applying machine learning methods to time series.

Who is this book for?

This book is ideal for data analysts, data scientists, and Python developers who want instantly useful and practical recipes to implement today, and a comprehensive reference book for tomorrow. Basic knowledge of the Python Programming language is a must, while familiarity with statistics will help you get the most out of this book.

What you will learn

  • Visualize time series data with ease
  • Characterize seasonal and correlation patterns through autocorrelation and statistical techniques
  • Get to grips with classical time series models such as ARMA, ARIMA, and more
  • Understand modern time series methods including the latest deep learning and gradient boosting methods
  • Choose the right method to solve time-series problems
  • Become familiar with libraries such as Prophet, sktime, statsmodels, XGBoost, and TensorFlow
  • Understand both the advantages and disadvantages of common models
  • Evaluate high-performance forecasting solutions
Estimated delivery fee Deliver to United States

Economy delivery 10 - 13 business days

Free $6.95

Premium delivery 6 - 9 business days

$21.95
(Includes tracking information)

Product Details

Country selected
Publication date, Length, Edition, Language, ISBN-13
Publication date : Apr 10, 2026
Length: 397 pages
Edition : 2nd
Language : English
ISBN-13 : 9781837631339
Category :

What do you get with Print?

Product feature icon Instant access to your digital copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Redeem a companion digital copy on all Print orders
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Shipping Address

Billing Address

Shipping Methods
Estimated delivery fee Deliver to United States

Economy delivery 10 - 13 business days

Free $6.95

Premium delivery 6 - 9 business days

$21.95
(Includes tracking information)

Product Details

Publication date : Apr 10, 2026
Length: 397 pages
Edition : 2nd
Language : English
ISBN-13 : 9781837631339
Category :

Packt Subscriptions

See our plans and pricing
Modal Close icon
$19.99 billed monthly
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Simple pricing, no contract
$199.99 billed annually
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just $5 each
Feature tick icon Exclusive print discounts
$279.99 billed in 18 months
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just $5 each
Feature tick icon Exclusive print discounts

Table of Contents

3 Chapters
Machine Learning for Time-Series with Python, Second Edition: Use Python to forecast, predict, and detect anomalies with state-of-the-art machine learning methods Chevron down icon Chevron up icon
Introduction Chevron down icon Chevron up icon
Dealing with Time Series in Python Chevron down icon Chevron up icon

Customer reviews

Rating distribution
Full star icon Full star icon Half star icon Empty star icon Empty star icon 2.5
(2 Ratings)
5 star 0%
4 star 50%
3 star 0%
2 star 0%
1 star 50%
Meir Jul 14, 2024
Full star icon Full star icon Full star icon Full star icon Empty star icon 4
instead of ```from pandas as read_csv should be from pandas import rad_csv
Subscriber review Packt
Manish Jun 10, 2024
Full star icon Empty star icon Empty star icon Empty star icon Empty star icon 1
Poorly written. - "machine learning methods on tabular data is that the data is that the data" what the heck is this? ARIMA - gives the acronym but doesn't say what it is? barely explains the examples.
Subscriber review Packt
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

What is the digital copy I get with my Print order? Chevron down icon Chevron up icon

When you buy any Print edition of our Books, you can redeem (for free) the eBook edition of the Print Book you’ve purchased. This gives you instant access to your book when you make an order via PDF, EPUB or our online Reader experience.

What is the delivery time and cost of print book? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela
What is custom duty/charge? Chevron down icon Chevron up icon

Customs duty are charges levied on goods when they cross international borders. It is a tax that is imposed on imported goods. These duties are charged by special authorities and bodies created by local governments and are meant to protect local industries, economies, and businesses.

Do I have to pay customs charges for the print book order? Chevron down icon Chevron up icon

The orders shipped to the countries that are listed under EU27 will not bear custom charges. They are paid by Packt as part of the order.

List of EU27 countries: www.gov.uk/eu-eea:

A custom duty or localized taxes may be applicable on the shipment and would be charged by the recipient country outside of the EU27 which should be paid by the customer and these duties are not included in the shipping charges been charged on the order.

How do I know my custom duty charges? Chevron down icon Chevron up icon

The amount of duty payable varies greatly depending on the imported goods, the country of origin and several other factors like the total invoice amount or dimensions like weight, and other such criteria applicable in your country.

For example:

  • If you live in Mexico, and the declared value of your ordered items is over $ 50, for you to receive a package, you will have to pay additional import tax of 19% which will be $ 9.50 to the courier service.
  • Whereas if you live in Turkey, and the declared value of your ordered items is over € 22, for you to receive a package, you will have to pay additional import tax of 18% which will be € 3.96 to the courier service.
How can I cancel my order? Chevron down icon Chevron up icon

Cancellation Policy for Published Printed Books:

You can cancel any order within 1 hour of placing the order. Simply contact customercare@packt.com with your order details or payment transaction id. If your order has already started the shipment process, we will do our best to stop it. However, if it is already on the way to you then when you receive it, you can contact us at customercare@packt.com using the returns and refund process.

Please understand that Packt Publishing cannot provide refunds or cancel any order except for the cases described in our Return Policy (i.e. Packt Publishing agrees to replace your printed book because it arrives damaged or material defect in book), Packt Publishing will not accept returns.

What is your returns and refunds policy? Chevron down icon Chevron up icon

Return Policy:

We want you to be happy with your purchase from Packtpub.com. We will not hassle you with returning print books to us. If the print book you receive from us is incorrect, damaged, doesn't work or is unacceptably late, please contact Customer Relations Team on customercare@packt.com with the order number and issue details as explained below:

  1. If you ordered (eBook, Video or Print Book) incorrectly or accidentally, please contact Customer Relations Team on customercare@packt.com within one hour of placing the order and we will replace/refund you the item cost.
  2. Sadly, if your eBook or Video file is faulty or a fault occurs during the eBook or Video being made available to you, i.e. during download then you should contact Customer Relations Team within 14 days of purchase on customercare@packt.com who will be able to resolve this issue for you.
  3. You will have a choice of replacement or refund of the problem items.(damaged, defective or incorrect)
  4. Once Customer Care Team confirms that you will be refunded, you should receive the refund within 10 to 12 working days.
  5. If you are only requesting a refund of one book from a multiple order, then we will refund you the appropriate single item.
  6. Where the items were shipped under a free shipping offer, there will be no shipping costs to refund.

On the off chance your printed book arrives damaged, with book material defect, contact our Customer Relation Team on customercare@packt.com within 14 days of receipt of the book with appropriate evidence of damage and we will work with you to secure a replacement copy, if necessary. Please note that each printed book you order from us is individually made by Packt's professional book-printing partner which is on a print-on-demand basis.

What tax is charged? Chevron down icon Chevron up icon

Currently, no tax is charged on the purchase of any print book (subject to change based on the laws and regulations). A localized VAT fee is charged only to our European and UK customers on eBooks, Video and subscriptions that they buy. GST is charged to Indian customers for eBooks and video purchases.

What payment methods can I use? Chevron down icon Chevron up icon

You can pay with the following card types:

  1. Visa Debit
  2. Visa Credit
  3. MasterCard
  4. PayPal
What is the delivery time and cost of print books? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela