So far, our focus in this chapter was mainly on the attributes of the date and time classes. Let's now connect the dots and see some useful applications of time series data. As introduced in Chapter 1, Introduction to Time Series Analysis and R, the main characteristic of time series data is its time index (or timestamp), an equally spaced time interval. The base package provides two pairs of functions, seq.Date and seq.POSIXt, to create a time index vector with Date or POSIX objects respectively. The main difference between the two functions (besides the class of the output) is the units of the time interval. It will make sense to use the seq.Date function to generate a time sequence with daily frequency or lower (for example, weekly, monthly, and so on) and as.POSIXt in other instances (for higher frequencies than daily, such as hourly, half...
United States
United Kingdom
India
Germany
France
Canada
Russia
Spain
Brazil
Australia
Argentina
Austria
Belgium
Bulgaria
Chile
Colombia
Cyprus
Czechia
Denmark
Ecuador
Egypt
Estonia
Finland
Greece
Hungary
Indonesia
Ireland
Italy
Japan
Latvia
Lithuania
Luxembourg
Malaysia
Malta
Mexico
Netherlands
New Zealand
Norway
Philippines
Poland
Portugal
Romania
Singapore
Slovakia
Slovenia
South Africa
South Korea
Sweden
Switzerland
Taiwan
Thailand
Turkey
Ukraine