Partial implementation of trading.