#Identify cost-effective actions based on random vectors of benefits and costs
benefit <- runif(50,min=0,max=10)
cost <- runif(50, min=0,max=1000)
CE <- CEfinder(benefit, cost)
BBfinder(benefit, cost, CE)
#Identify cost-effective actions based on a small number of user-specified benefits and costs
restben <- c(0, 10, 5, 20, 20)
restcost <- c(0, 100, 100, 200, 150)
restCE <- CEfinder(restben, restcost)
BBfinder(restben, restcost, restCE)
Run the code above in your browser using DataLab