FCNAgent#
- class pams.agents.FCNAgent(agent_id, prng, simulator, name, logger=None)[ソース]#
FCN (Fundamental, Chartist, Noise) Agent class
This class inherits from the
pams.agents.Agent
class.An order decision mechanism proposed in Chiarella & Iori (2004). It employs two simple margin-based random tradings. Given an expected future price p, submit an order of price
"fixed" : \(p (1 ± k)\) where \(0 \leq k \leq 1\)
"normal" : \(p + N(0, k)\) where \(k > 0\)
参照
Chiarella, C., & Iori, G. (2002). A simulation analysis of the microstructure of double auction markets. Quantitative Finance, 2(5), 346–353. https://doi.org/10.1088/1469-7688/2/5/303
- is_finite(x)[ソース]#
determine if it is a valid value.
- パラメータ:
x (float) -- value.
- 戻り値:
whether or not it is a valid (not NaN, finite) value.
- 戻り値の型:
bool
- setup(settings, accessible_markets_ids, *args, **kwargs)[ソース]#
agent setup. Usually be called from simulator/runner automatically.
- パラメータ:
settings (Dict[str, Any]) -- agent configuration. This can include the parameters "fundamentalWeight", "chartWeight", "noiseWeight", "noiseScale", "timeWindowSize", "orderMargin", "marginType", and "meanReversionTime".
accessible_markets_ids (List[int]) -- list of market IDs.
- 戻り値の型:
None
- 戻り値:
None