Feature/get ticks revamped #200

Merged
merged 8 commits into from Sep 16, 2016

Projects

None yet

3 participants

@eddelbuettel
Member

No description provided.

@armstrtw armstrtw merged commit 2b2f259 into master Sep 16, 2016

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
@eddelbuettel
Member

Yay :)

Big, big thanks to @joel23888 for nudging us along. This is now much, much better. I'll revamp the (currently mostly useless too) getMultipleTicks() next.

@armstrtw
Contributor

Thanks guys.

@eddelbuettel eddelbuettel deleted the feature/getTicks-revamped branch Sep 16, 2016
@joel23888
Contributor

FWIW I ran a quick manual test on some stock data and it looks good. See below.

> st <- lubridate::ymd_hms("20160915T10:54:00", tz = "Asia/Tokyo")
> et <- lubridate::ymd_hms("20160915T10:55:00", tz = "Asia/Tokyo")
> d3 <- getTicks("1588 JT Equity", eventType = "ASK", startTime = st, endTime = et)
> str(d3)
'data.frame':   20 obs. of  5 variables:
 $ times   : POSIXct, format: "2016-09-15 01:54:00" "2016-09-15 01:54:00" ...
 $ type    : Factor w/ 1 level "ASK": 1 1 1 1 1 1 1 1 1 1 ...
 $ value   : num  12560 12520 12510 12520 12520 ...
 $ size    : num  9 500 10 500 500 10 500 500 9 500 ...
 $ condcode: Factor w/ 2 levels "","SPEC": 1 1 1 1 1 1 1 1 1 1 ...
> d3
                 times type value size condcode
1  2016-09-15 01:54:00  ASK 12560    9         
2  2016-09-15 01:54:00  ASK 12520  500         
3  2016-09-15 01:54:00  ASK 12510   10         
4  2016-09-15 01:54:01  ASK 12520  500         
5  2016-09-15 01:54:13  ASK 12520  500         
6  2016-09-15 01:54:13  ASK 12510   10         
7  2016-09-15 01:54:14  ASK 12520  500         
8  2016-09-15 01:54:14  ASK 12520  500         
9  2016-09-15 01:54:14  ASK 12560    9         
10 2016-09-15 01:54:14  ASK 12530  500         
11 2016-09-15 01:54:23  ASK 12560    9         
12 2016-09-15 01:54:23  ASK 12520  500         
13 2016-09-15 01:54:25  ASK 12440   50     SPEC
14 2016-09-15 01:54:29  ASK 12440   50     SPEC
15 2016-09-15 01:54:29  ASK 12440   50     SPEC
16 2016-09-15 01:54:39  ASK 12520  500     SPEC
17 2016-09-15 01:54:45  ASK 12560    9     SPEC
18 2016-09-15 01:54:45  ASK 12560  509     SPEC
19 2016-09-15 01:54:45  ASK 12560  519     SPEC
20 2016-09-15 01:54:56  ASK 12560  509     SPEC
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment