Getting Started
TimeSeries is a registered package. To add it to your Julia packages, simply do the following in REPL:
julia> Pkg.add("TimeSeries")
Throughout this tutorial, we'll be using historical financial data sets, which are made available in the MarketData package. MarketData is also registered and can be added:
julia> Pkg.add("MarketData")
To create dummy data without using the MarketData package, simply use the following code block:
julia> using Datesjulia> dates = Date(2018, 1, 1):Day(1):Date(2018, 12, 31)Date("2018-01-01"):Day(1):Date("2018-12-31")julia> ta = TimeArray(dates, rand(length(dates)))365×1 TimeArray{Float64, 1, Date, Vector{Float64}} 2018-01-01 to 2018-12-31 ┌────────────┬───────────┐ │ │ A │ ├────────────┼───────────┤ │ 2018-01-01 │ 0.978338 │ │ 2018-01-02 │ 0.0285585 │ │ 2018-01-03 │ 0.278321 │ │ 2018-01-04 │ 0.693449 │ │ 2018-01-05 │ 0.659938 │ │ 2018-01-06 │ 0.444767 │ │ 2018-01-07 │ 0.19779 │ │ 2018-01-08 │ 0.347989 │ │ ⋮ │ ⋮ │ │ 2018-12-25 │ 0.913229 │ │ 2018-12-26 │ 0.800242 │ │ 2018-12-27 │ 0.746186 │ │ 2018-12-28 │ 0.167193 │ │ 2018-12-29 │ 0.40582 │ │ 2018-12-30 │ 0.369837 │ │ 2018-12-31 │ 0.736137 │ └────────────┴───────────┘ 350 rows omitted