Hello!
I apologize for possibly a simple question. I’m new to Julia, and maybe I didn’t find something in the description of StatsModels and TimeSeries.

I have DataFrame data2 with time (yyyy-mm-dd) and 2 column with data Y1 and Y2

Hello @nilshg
Thank you for your response and example.

I try

julia> lm(@formula(Y1 ~ Time), data2)

and error

Error showing value of type StatsModels.DataFrameRegressionModel{LinearModel{LmResp{Array{Float64,1}},DensePredChol{Float64,LinearAlgebra.Cholesky{Float64,Array{Float64,2}}}},Array{Float64,2}}:
ERROR: ArgumentError: FDist: the condition ν1 > zero(ν1) && ν2 > zero(ν2) is not satisfied.

I think you just need to convert your Date column to a numeric variable, e.g. using df.Time2 = datetime2rata.(df.Time). By default non-numeric variables are treated as categorical.