Skip to content

summary_id is incorrectly set to -1 for wheatsheaf mean outputs if no losses #399

@carlfischerjba

Description

@carlfischerjba

Issue Description

We've run a portfolio with terms such that the insured losses are all zero. This leads to aalcalc, pltcalc and wheatsheaf_aep/oep files that are empty except for the header. That's fine. But the wheatsheaf_mean_aep/oep files are populated with a number of zero rows (fine but inconsistent with the other outputs) and a summary_id which does not match the one in the summary-info file. This causes some of our scripts to fail.

We'll add special handling for this case so there's no urgency to fix at your end, especially if ktools will be rewritten soon.

Steps to Reproduce (Bugs only)

  1. Create a portfolio with terms such that the insured losses will be zero.
  2. Run an analysis requesting the legacy wheatsheaf_mean EP outputs.
  3. Observe the mismatch in summary ids.

Version / Environment information

Oasis 2.3.10

Example data / logs

il_S1_leccalc_wheatsheaf_mean_oep.csv has summary_id set to -1.

summary_id,type,return_period,loss
-1,2,1500.000000,0.000000
-1,2,1000.000000,0.000000
-1,2,900.000000,0.000000
-1,2,800.000000,0.000000
-1,2,700.000000,0.000000
-1,2,600.000000,0.000000
-1,2,500.000000,0.000000
-1,2,400.000000,0.000000
-1,2,300.000000,0.000000
-1,2,250.000000,0.000000
-1,2,200.000000,0.000000
-1,2,150.000000,0.000000
-1,2,100.000000,0.000000
-1,2,75.000000,0.000000
-1,2,50.000000,0.000000
-1,2,25.000000,0.000000
-1,2,20.000000,0.000000
-1,2,10.000000,0.000000
-1,2,5.000000,0.000000
-1,2,2.000000,0.000000

But the real summary_id as defined in il_S1_summary-info.csv is 1.

summary_id,_not_set_,tiv
1,All-Risks,123546789.0

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Status

Todo

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions