From 1f2cb6ae894c99f98caca23751841782b10cd069 Mon Sep 17 00:00:00 2001 From: Vaibhav Kumar Dixit <vaibhavyashdixit@gmail.com> Date: Sat, 28 Sep 2024 09:28:09 -0400 Subject: [PATCH] Apply suggestions from code review --- docs/src/getting_started/fit_simulation.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/src/getting_started/fit_simulation.md b/docs/src/getting_started/fit_simulation.md index cfef3f3bf7..5c845decf2 100644 --- a/docs/src/getting_started/fit_simulation.md +++ b/docs/src/getting_started/fit_simulation.md @@ -311,9 +311,9 @@ More details about callbacks in Optimization.jl can be found [here](https://docs.sciml.ai/Optimization/stable/API/solve/). ```@example odefit -function callback(p, l) +function callback(state, l) display(l) - newprob = remake(prob, p = p) + newprob = remake(prob, p = state.u) sol = solve(newprob, saveat = 1) plt = plot(sol, ylim = (0, 6), label = ["Current x Prediction" "Current y Prediction"]) scatter!(plt, t_data, xy_data', label = ["x Data" "y Data"])