x <- c(1, 0.000495134903027804, 0.787229130724068, 0.71154311082138,
0.0669802789251427, 0.310872967333683, 1, 1, 1, 1, 0.162030982251957,
1, 1, 0.322530106394859, 1, 1, 1, 0.60805410798081, 0.660941675188664, 1)
#empirical total loss (true value is 1/2)
etl(x)
Run the code above in your browser using DataLab