Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
MarkovProcesses.jl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Bentriou Mahmoud
MarkovProcesses.jl
Commits
52bdf469
Commit
52bdf469
authored
4 years ago
by
Bentriou Mahmoud
Browse files
Options
Downloads
Patches
Plain Diff
small change in plots
parent
5b526616
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
core/plots.jl
+4
-4
4 additions, 4 deletions
core/plots.jl
with
4 additions
and
4 deletions
core/plots.jl
+
4
−
4
View file @
52bdf469
...
...
@@ -22,7 +22,7 @@ function plot(σ::AbstractTrajectory, vars::VariableModel...; plot_transitions::
end
# Plots
p
=
plot
(
title
=
"Trajectory of
$
(Symbol(typeof(σ.m)))
model
"
,
palette
=
:
lightrainbow
,
legend
=
:
outertopright
,
background_color_legend
=:
transparent
,
dpi
=
480
)
p
=
plot
(
title
=
"Trajectory of
$
(Symbol(typeof(σ.m)))"
,
palette
=
:
lightrainbow
,
legend
=
:
outertopright
,
background_color_legend
=:
transparent
,
dpi
=
480
)
for
var
in
to_plot
@assert
var
in
get_obs_var
(
σ
)
"Variable
$
var is not observed."
plot!
(
p
,
times
(
σ
),
σ
[
var
],
...
...
@@ -106,7 +106,7 @@ function plot_periodic_trajectory(A::LHA, σ::SynchronizedTrajectory, sym_obs::S
break
end
end
p
=
plot
(
title
=
"Oscillatory trajectory of
$
(Symbol(typeof(σ.m)))
model
"
,
palette
=
:
lightrainbow
,
p
=
plot
(
title
=
"Oscillatory trajectory of
$
(Symbol(typeof(σ.m)))"
,
palette
=
:
lightrainbow
,
background_color_legend
=:
transparent
,
dpi
=
480
,
legend
=
:
outertopright
)
#legendfontsize, legend
colors_loc
=
Dict
(
:
l0
=>
:
silver
,
:
l0prime
=>
:
silver
,
:
final
=>
:
black
,
:
low
=>
:
skyblue2
,
:
mid
=>
:
orange
,
:
high
=>
:
red
)
...
...
@@ -118,8 +118,8 @@ function plot_periodic_trajectory(A::LHA, σ::SynchronizedTrajectory, sym_obs::S
markersize
=
1.0
,
markershape
=
:
cross
,
label
=
label_state
,
xlabel
=
"Time"
,
ylabel
=
"Species
$
sym_obs"
)
end
annot_n
=
[(
times
(
σ
)[
idx_n
[
i
]],
σ
[
sym_obs
][
idx_n
[
i
]]
-
1
0
,
text
(
"n =
$
(values_n[i])"
,
annot_size
,
:
top
))
for
i
=
eachindex
(
idx_n
)]
annot_tp
=
[(
times
(
σ
)[
idx_n
[
i
]],
σ
[
sym_obs
][
idx_n
[
i
]]
-
1
0
,
text
(
"tp =
$
(round(values_tp[i], digits = 5))"
,
annot_size
,
:
bottom
))
for
i
=
eachindex
(
idx_n
)]
annot_n
=
[(
times
(
σ
)[
idx_n
[
i
]],
σ
[
sym_obs
][
idx_n
[
i
]]
-
2
0
,
text
(
"n =
$
(values_n[i])"
,
annot_size
,
:
top
))
for
i
=
eachindex
(
idx_n
)]
annot_tp
=
[(
times
(
σ
)[
idx_n
[
i
]],
σ
[
sym_obs
][
idx_n
[
i
]]
-
2
0
,
text
(
"tp =
$
(round(values_tp[i], digits = 5))"
,
annot_size
,
:
bottom
))
for
i
=
eachindex
(
idx_n
)]
annots
=
(
show_tp
)
?
vcat
(
annot_n
,
annot_tp
)
:
annot_n
scatter!
(
p
,
times
(
σ
)[
idx_n
],
σ
[
sym_obs
][
idx_n
],
annotations
=
annots
,
markershape
=
:
utriangle
,
markersize
=
3
,
label
=
"n"
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment