-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add diff_map to plot difference to counterfactual map
- Loading branch information
Showing
7 changed files
with
85 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
using WGLMakie, GeoMakie, GraphMakie | ||
using ADRIA: viz | ||
using ADRIA: YAXArray | ||
using ADRIA: metrics, metrics.cf_difference_loc | ||
|
||
if !@isdefined(TEST_RS) | ||
const TEST_DOM, TEST_N_SAMPLES, TEST_SCENS, TEST_RS = test_rs() | ||
end | ||
|
||
Makie.inline!(false) | ||
@testset "spatial" begin | ||
fig_opts = Dict(:size => (1600, 800)) | ||
|
||
@testset "diff_map" begin | ||
gd_diff::YAXArray{<:Real,2}, ug_diff::YAXArray{<:Real,2} = cf_difference_loc( | ||
metrics.relative_cover(TEST_RS), TEST_SCENS | ||
) | ||
|
||
viz.diff_map(TEST_RS, gd_diff[2, :]; fig_opts=fig_opts) | ||
viz.diff_map(TEST_RS, ug_diff[2, :]; fig_opts=fig_opts) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters