Ben
> Perhaps you can specify your question more precisely, or differently. > The way I interpret it, if there are no interactions in price > (e.g. you get a discount for buying more than one book at a time) > or in value (e.g. you learn more from one book having read another), > then you get the best value/price ratio by taking only the book with > the highest value/price. (If you take no books at all, your value/price > ratio is undefined.) The algebra below shows that combining a lower > value/price book with a higher one always lowers your overall value/price > ratio. > Thanks, for the pointers on R functions. My question was as superficial as it sounded. I have a commercial programme that does this (one of several that are available), and wondered if there was an R package that provided the same tools. It's a common tool, and I had hoped to have explained enough to allow an appropriate package to be identified, so I could have a quick look at what it does. But having started this, I now feel obliged to clarify the question. I only chose books as an easy example, you could substitute alternative marketing strategies, monitoring programmes, choice of ornaments for a new house, or holidays etc. So there could be only a few potential combinations or hundreds. But to stick with the books, and only three options: A, B and C Book A costs $100 and I have given it a subjective value of 50 Book B costs $36 and I have given it a subjective value of 60 Book C costs $50 and I have given it a subjective value of 80 So book A is costing me $2 per value unit, Book B $0.6 per value unit and book C £0.63 per value unit. Buying books A+B gives me a $1.24 per value unit Buying books A+C gives $1.07 per value unit Buying books B+C gives 0.61 per value unit Buying books A+B+C gives 0.97 per value unit So in terms of value for money, there are three contenders Book B on its own, Book C on its own, or buying both books B and C. Book B $36.00 and value 60 Book C $50.00 and value 80 Book B+C at $76.00 and value 140 Depending on how you are using this tool, you can either use it to decide how spend an existing budget, or use it to set a budget. Seems hardly worth the bother for three books but if you are looking at 20 books or 30 different monitoring options etc, it gives a useful insight into how best to spend or set a budget The commercial software graphs this costs vs values so you usually end up with some sort of an asymptotic graph where you can see that spending below a certain budget gives a very poor return. Graham [[alternative HTML version deleted]]
______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.