package agents; import java.util.ArrayList; import master.Product; public class Agent5405 extends Agent { public Agent5405(String id) { super(id); // TODO Auto-generated constructor stub } @Override public boolean willBuy(Product prod, double probOfGood) { // TODO Auto-generated method stub if(/*(prod.getValue()-prod.getPrice())*probOfGood > 100 //is the expected return better than just sitting out? && */ prod.getPrice()*(1-probOfGood)<(prod.getValue()-prod.getPrice())*probOfGood )//is the expected return better than the expected loss { return true; } else { return false; } } @Override public void learn(ArrayList> trainingInstances) { // TODO Auto-generated method stub } @Override public double computeProbOfGood(ArrayList prodFeatures) { // TODO Auto-generated method stub return 0; } }