Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mooc-rr
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
3e6bf7b47a05a05ae3d6af86121dcb5d
mooc-rr
Commits
4c66a326
Commit
4c66a326
authored
Apr 17, 2020
by
François Févotte
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Meilleur intervalle de confiance pour les prédictions
parent
26cc1e49
Changes
3
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
82133 additions
and
80467 deletions
+82133
-80467
exercice.html
module3/exo3/exercice.html
+82118
-80458
exercice.jmd
module3/exo3/exercice.jmd
+15
-9
exercice.pdf
module3/exo3/exercice.pdf
+0
-0
No files found.
module3/exo3/exercice.html
View file @
4c66a326
This diff is collapsed.
Click to expand it.
module3/exo3/exercice.jmd
View file @
4c66a326
...
@@ -613,15 +613,15 @@ négligeable. L'incertitude sur $\beta$ est en particulier de nature à engendre
...
@@ -613,15 +613,15 @@ négligeable. L'incertitude sur $\beta$ est en particulier de nature à engendre
une perte de prédictibilité du modèle en temps long.
une perte de prédictibilité du modèle en temps long.
```julia; echo=false; results="
raw
"
```julia; echo=false; results="
raw
"
data.theta_pred = predict(model, data)
pred = predict(model, data, interval=:prediction, level=0.95)
data.theta_pred = pred.prediction
data.theta_pred1 = pred.prediction .- pred.lower
data.theta_pred2 = pred.upper .- pred.prediction
plot(xlabel="
Date
", ylabel="
CO2
[
ppm
]
")
plot(xlabel="
Date
", ylabel="
CO2
[
ppm
]
")
plot!(data_raw.date, data_raw.co2, label="
mesures
")
plot!(data_raw.date, data_raw.co2, label="
mesures
")
plot!(data.date, data.theta_pred, label="
mod
è
le
theta
", linewidth=3)
plot!(data.date, data.theta_pred, label="
mod
è
le
theta
",
plot!(data.date, α .+ β1 * data.date_num .+ γ*data.date_num.^2,
ribbon = (data.theta_pred1, data.theta_pred2))
linecolor="
red
", label="
mod
è
le
theta
(
IC
95
%
sur
beta
)
")
plot!(data.date, α .+ β2 * data.date_num .+ γ*data.date_num.^2,
linecolor="
red
", label=nothing)
disp()
disp()
```
```
...
@@ -654,7 +654,11 @@ Le modèle `GLM` précédemment calibré est utilisé pour prédire $\theta(t)$.
...
@@ -654,7 +654,11 @@ Le modèle `GLM` précédemment calibré est utilisé pour prédire $\theta(t)$.
ajoute la fonction de forme annuelle $\phi(t)$ par périodicité.
ajoute la fonction de forme annuelle $\phi(t)$ par périodicité.
```julia; results="
raw
"
```julia; results="
raw
"
prediction.theta = predict(model, prediction)
pred = predict(model, prediction, interval=:prediction, level=0.95)
prediction.theta = pred.prediction
prediction.theta1 = pred.prediction .- pred.lower
prediction.theta2 = pred.upper .- pred.prediction
prediction = join(prediction, avg, on=:day)
prediction = join(prediction, avg, on=:day)
prediction.co2 = prediction.theta .+ prediction.phi_mean
prediction.co2 = prediction.theta .+ prediction.phi_mean
...
@@ -670,7 +674,9 @@ d'extrapolation ; on observe un décalage significatif et croissant ensuite.
...
@@ -670,7 +674,9 @@ d'extrapolation ; on observe un décalage significatif et croissant ensuite.
idx = data_raw.date .> Date(lastyear)
idx = data_raw.date .> Date(lastyear)
plot(xlabel="
Date
", ylabel="
CO2
[
ppm
]
")
plot(xlabel="
Date
", ylabel="
CO2
[
ppm
]
")
plot!(data_raw.date[idx], data_raw.co2[idx], label="
mesures
")
plot!(data_raw.date[idx], data_raw.co2[idx], label="
mesures
")
plot!(prediction.date, prediction.theta, label="
tendance
", linewidth=2)
plot!(prediction.date, prediction.theta, label="
tendance
",
linewidth=2,
ribbon = (prediction.theta1, prediction.theta2))
plot!(prediction.date, prediction.co2, label="
pr
é
diction
", linewidth=2)
plot!(prediction.date, prediction.co2, label="
pr
é
diction
", linewidth=2)
disp()
disp()
```
```
...
...
module3/exo3/exercice.pdf
View file @
4c66a326
No preview for this file type
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment