|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectuk.ac.liv.auction.agent.AbstractStrategy
uk.ac.liv.auction.agent.FixedQuantityStrategyImpl
uk.ac.liv.auction.agent.KaplanStrategy
An implementation of Todd Kaplan's sniping strategy. Agents using this strategy wait until the last minute before attempting to "steal the bid". See
"Behaviour of trading automata in a computerized double auction market" J. Rust, J. Miller and R. Palmer in "The Double Auction Market: Institutions, Theories and Evidence" 1992, Addison-Wesley
Note that you must configure a logger of type DailyStatsMarketDataLogger in order to use this strategy.
Parameters
| base.s double >= 0 |
(the spread factor) |
| base.t double >= 0 |
(the time factor) |
DailyStatsReport,
Serialized Form| Field Summary | |
protected DailyStatsReport |
dailyStats
|
static java.lang.String |
P_S
|
static java.lang.String |
P_T
|
protected MarketQuote |
quote
|
protected double |
s
The spread factor. |
protected double |
t
The time factor. |
| Fields inherited from class uk.ac.liv.auction.agent.AbstractStrategy |
agent, auction, currentShout |
| Constructor Summary | |
KaplanStrategy()
|
|
| Method Summary | |
void |
auctionOpen(AuctionOpenEvent event)
|
void |
endOfRound(Auction auction)
|
protected void |
error(DataUnavailableException e)
|
void |
eventOccurred(AuctionEvent event)
|
double |
getS()
|
double |
getT()
|
boolean |
juicyOffer()
|
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. |
boolean |
smallSpread()
|
boolean |
timeRunningOut()
|
java.lang.String |
toString()
|
| 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, 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 |
protected double t
protected double s
protected MarketQuote quote
protected DailyStatsReport dailyStats
public static final java.lang.String P_T
public static final java.lang.String P_S
| Constructor Detail |
public KaplanStrategy()
| Method Detail |
public void setup(ec.util.ParameterDatabase parameters,
ec.util.Parameter base)
Parameterizable
setup in interface Parameterizablesetup in class FixedQuantityStrategyImplpublic java.lang.Object protoClone()
protoClone in interface PrototypeableprotoClone in class AbstractStrategypublic void eventOccurred(AuctionEvent event)
eventOccurred in interface AuctionEventListenereventOccurred in class AbstractStrategypublic void auctionOpen(AuctionOpenEvent event)
public boolean modifyShout(Shout.MutableShout shout)
AbstractStrategy
modifyShout in class FixedQuantityStrategyImplpublic void endOfRound(Auction auction)
endOfRound in class AbstractStrategypublic boolean juicyOffer()
public boolean smallSpread()
public boolean timeRunningOut()
public double getS()
public double getT()
public java.lang.String toString()
protected void error(DataUnavailableException e)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||