How do I apply a max amount to a number using a variable.
I am dealing with Insurance claims and one of the things we like to play with is called a "Stop-Loss" which is basically insurance on top of insurance where if a claim exceeds a certain amount that insurance would kick in and cover the rest of the claim.
For example my stop loss is at $75,000/yr per person any claims above that amount is not "My" responsibility but covered by the Stop-Loss insurance. So to Analyze my cost I need to be able to "Cap" my cost at that amount. So I need to summarize the claims per person per (time period) and apply that amount. If the amount exceeds that amount, my cost would be the amount, otherwise it would be the summarized amount.
Examples P represents a person, PP represents the total amount paid out including any amount supplied by the stop loss insurance.