MCPcopy Create free account
hub / github.com/Open-Quant/openquant / sample_trades

Function sample_trades

crates/openquant/tests/data_structures_standard.rs:8–16  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

6}
7
8fn sample_trades() -> Vec<Trade> {
9 vec![
10 Trade { timestamp: ts(0), price: 100.0, volume: 1.0 },
11 Trade { timestamp: ts(30), price: 101.0, volume: 2.0 },
12 Trade { timestamp: ts(60), price: 102.0, volume: 3.0 },
13 Trade { timestamp: ts(150), price: 103.0, volume: 4.0 },
14 Trade { timestamp: ts(210), price: 104.0, volume: 5.0 },
15 ]
16}
17
18#[test]
19fn tick_volume_dollar_bars() {

Callers 2

tick_volume_dollar_barsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected