www.pudn.com > asm_java.zip > AgentVariants.java
package asm;
/**
* Title: Artificial Stock Market
* Description: 人工模拟股市(来源:SFI的Swarm版本)的Java版本
* Copyright: Copyright (c) 2003
* Company: http://agents.yeah.net
* @author jake
* @version 1.0
*/
public class AgentVariants {
public double demand; /*" bid or -offer"*/
public double profit; /*" exp-weighted moving average "*/
public double wealth; /*" total agent wealth "*/
public double position; /*" total shares of stock "*/
public double cash; /*" total agent cash position "*/
public int currentTime; /*"The agent regularly checks with Swarm to see what time it is"*/
public double avspecificity; /*'average specificity of active forecasts"*/
public double forecast; /*"prediction of stock price: (trialprice+dividend)*pdcoeff + offset."*/
public double global_mean; /*"price+dividend"*/
public double realDeviation; /*" ftarget-lforecast: how far off was the agent's forecast?"*/
public double variance; /*"an Exp.Weighted MA of the agent's historical variance: Combine the old variance with deviation^squared, as in: bv*variance + av*deviation*deviation"*/
public double pdcoeff; /*" coefficient used in predicting stock price, recalculated each period in prepareForTrading"*/
public double offset; /*" coefficient used in predicting stock price, recalculated each period in prepareForTrading"*/
public double divisor; /*" a coefficient used to calculate demand for stock. It is a proportion (lambda) of forecastvar (basically, accuracy of forecasts)"*/
public int gacount;
public AgentVariants() {
}
}