create_orders: create_orders

Description Usage Arguments

View source: R/order_functions.R

Description

Generate orders based on roulette wheel selection.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
create_orders(
  time_stamp,
  order_number,
  market_sell,
  market_buy,
  limit_ask,
  limit_bid,
  cancel_bid,
  cancel_ask
)

Arguments

time_stamp

The time of the order

order_number

The order number (i.e. the event number in the simulation loop)

market_sell

The arrival intensity of market sell orders.

market_buy

The arrival intensity of market buy orders.

limit_ask

The arrival intensity of limit ask orders.

limit_bid

The arrival intensity of limit bid orders.

cancel_bid

The cancellation intensity of limit bid orders.

cancel_ask

The cancellation intensity of limit ask orders.

This function creates orders. The order type is based on roulette wheel selection, where the "sizes" of the roulette wheel segments are the intensity rates of the the order types.

These intensity rate is fed into a Poission distribution to create the timestamp of the order.

The order size is created as a random multiple of some number (e.g. all order sizes are multiples of 50)


norwegianblueparrot/marketsimulatr documentation built on Dec. 22, 2021, 3:13 a.m.