-
Notifications
You must be signed in to change notification settings - Fork 6
Unexpected behavior when using AAL.get_summary() with extra parameters #70
Description
Hi,
I am having trouble understanding differences in the behavior of the aal API depending on whether specific depths parameters are provided.
For instance, without any depth parameter the following call returns an average annual loss of $59,207 for the mid scenario in 2020
fs_aal = fs.aal.get_summary(
search_items=[110200183],
csv=True,
location_type="property",
output_dir="output_data/",
extra_param=None
)
fsid depth damage year low mid high
1 110200183 3 8983 2020 57699 59207 60256
2 110200183 15 39930 2020 57699 59207 60256
3 110200183 31 81500 2020 57699 59207 60256
4 110200183 3 8983 2050 58223 59731 60780
5 110200183 15 39930 2050 58223 59731 60780
6 110200183 31 81500 2050 58223 59731 60780
However, when manually providing the 3 default depth values the mid aal value changes to $80,647 (although the damages associated with each depth level are consistent with the previous call)
fs_aal = fs.aal.get_summary(
search_items=[110200183],
csv=True,
location_type="property",
output_dir="output_data/",
extra_param={"depths": [3,15,31]}
)
fsid depth damage year low mid high
1 110200183 3 8983 2020 80647 80647 80647
2 110200183 15 39930 2020 80647 80647 80647
3 110200183 31 81500 2020 80647 80647 80647
4 110200183 3 8983 2050 80647 80647 80647
5 110200183 15 39930 2050 80647 80647 80647
6 110200183 31 81500 2050 80647 80647 80647
In fact, providing any positive value of the depth parameter yields aal values of 80,647. See example below with a depth of 1:
fsid depth damage year low mid high
1 110200183 1 3803 2020 80647 80647 80647
2 110200183 1 3803 2050 80647 80647 80647
This could still make sense if i) the property 110200183 is below sea-level, ii) the total value of the structure is $80,647, iii) and if the aal mid value actually reports the total damage estimate without probability weighting when the depth is provided. However using location.get_detail I find that the elevation for this property is a high 699. Is there something I am missing?
Thanks a lot for this fantastic API,
Jo