uk.ac.liv.auction.agent
Class GDStrategy

java.lang.Object
  extended byuk.ac.liv.auction.agent.AbstractStrategy
      extended byuk.ac.liv.auction.agent.FixedQuantityStrategyImpl
          extended byuk.ac.liv.auction.agent.GDStrategy
All Implemented Interfaces:
AuctionEventListener, java.lang.Cloneable, FixedQuantityStrategy, Parameterizable, Prototypeable, Resetable, java.io.Serializable, Strategy

public class GDStrategy
extends FixedQuantityStrategyImpl
implements java.io.Serializable, Prototypeable

An implementation of the Gjerstad Dickhaut strategy. Agents using this strategy calculate the probability of any bid being accepted and bid to maximize expected profit. See

"Price Formation in Double Auctions" S. Gjerstad, J. Dickhaut and R. Palmer

Note that you must configure a logger of type HistoricalDataReport in order to use this strategy.

Parameters

base .maxprice
double >= 0
(max price in auction)

Version:
$Revision: 1.9 $
Author:
Marek Marcinkiewicz
See Also:
HistoricalDataReport, Serialized Form

Field Summary
protected  HistoricalDataReport historyStats
           
protected  double max
           
static double MAX_PRICE
           
protected  double maxPoint
           
static java.lang.String P_MAXPRICE
           
protected  MarketQuote quote
           
 
Fields inherited from class uk.ac.liv.auction.agent.AbstractStrategy
agent, auction, currentShout
 
Constructor Summary
GDStrategy()
           
 
Method Summary
 void auctionOpen(AuctionOpenEvent event)
           
 void endOfRound(Auction auction)
           
 void eventOccurred(AuctionEvent event)
           
 boolean modifyShout(Shout.MutableShout shout)
          Modify the price and quantity of the given shout according to this strategy.
 java.lang.Object protoClone()
           
 void setup(ec.util.ParameterDatabase parameters, ec.util.Parameter base)
          Initialise this object from a parameter database.
 
Methods inherited from class uk.ac.liv.auction.agent.FixedQuantityStrategyImpl
determineQuantity, getQuantity, setQuantity
 
Methods inherited from class uk.ac.liv.auction.agent.AbstractStrategy
getAgent, initialise, modifyShout, reset, setAgent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface uk.ac.liv.util.Resetable
reset
 
Methods inherited from interface uk.ac.liv.auction.agent.Strategy
modifyShout, setAgent
 

Field Detail

maxPoint

protected double maxPoint

max

protected double max

quote

protected MarketQuote quote

historyStats

protected HistoricalDataReport historyStats

P_MAXPRICE

public static final java.lang.String P_MAXPRICE
See Also:
Constant Field Values

MAX_PRICE

public static double MAX_PRICE
Constructor Detail

GDStrategy

public GDStrategy()
Method Detail

setup

public void setup(ec.util.ParameterDatabase parameters,
                  ec.util.Parameter base)
Description copied from interface: Parameterizable
Initialise this object from a parameter database.

Specified by:
setup in interface Parameterizable
Overrides:
setup in class FixedQuantityStrategyImpl

protoClone

public java.lang.Object protoClone()
Specified by:
protoClone in interface Prototypeable
Overrides:
protoClone in class AbstractStrategy

eventOccurred

public void eventOccurred(AuctionEvent event)
Specified by:
eventOccurred in interface AuctionEventListener
Overrides:
eventOccurred in class AbstractStrategy

auctionOpen

public void auctionOpen(AuctionOpenEvent event)

modifyShout

public boolean modifyShout(Shout.MutableShout shout)
Description copied from class: AbstractStrategy
Modify the price and quantity of the given shout according to this strategy.

Overrides:
modifyShout in class FixedQuantityStrategyImpl

endOfRound

public void endOfRound(Auction auction)
Specified by:
endOfRound in class AbstractStrategy