This function extracts a specific level of contour from a kde object.
This function only works for some levels that the kde object calculated
originally (associated with the constraints in the alpha
parameter).
extract_contour(kde_obj, alpha)
kde_obj | kde object |
---|---|
alpha | contour level which needs to be extracted. Scalar in the sequence from .01 to .99 by .01. A value of .95 gives a contour level associated with the cumulative prob of 95% (and 95% confidence interval) - which is technically 1-alpha. |
List of contours at (100*alpha level) for the kde object - there is a contour for each disconnected contour that forms the (100*alpha level)
This function (renamed as extract_countour
) is shared with TCpredictionbands on github:
TCpredictionbands.