Comments (11)
This looks great.
I need to clean up my branches and merge this into my fork. Then I can play it.
from apca.
Yeah, it's something that is on my TODO list, because I need it too, although not urgently. I looked at it briefly a while back and something about their design put me off. Will take another look.
from apca.
from apca.
Yep, sucks that they don't expose that properly, but perhaps it's for the better. I am importing all transactions into ledger and then have a script that spits out profit/loss per transaction or per-day. It works flawlessly, I have to say (and I wouldn't want to do it on the fly). But as you said it requires me to import fairly regularly because of the 100 item limit (has never been an issue so far, though).
from apca.
That's cool. I took a look at apcaledge. I'm still not sure how you're specifying the trade window.
My system is a lot of intraday trading. So I easily bust through 100 trades in a given day.
I'm also attempting to load the entire ledger at the start of my application, which requires pagination.
from apca.
It won't work in that case. I am relying on any trades not present in the ledger to be within the last 100 ones for the account. I don't do excessive amounts of trading yet, so that's why it has worked out so far. But it's also why I want this hooked up, too, because it will be a limitation eventually. In any case, I am working on getting page_size
and page_token
hooked up right now.
from apca.
Awesome! I appreciate it.
It's annoying because partial_fill is kinda useless for the ledger P/L from what I can tell.
I'm probably just going to store the ledger as a hash map of order Id and orders. Then sort by the timestamp when it's time to calculate P/L.
from apca.
Partial fills shouldn't matter at all for the ledger, should they? The knowledge of how much you ordered is not present there.
Here is what seems to be a working version: https://github.com/d-e-s-o/apca/tree/topic/paging
Feel free to give it a spin. Will hopefully polish and merge it by the weekend. Not sure if I'll cut a new release immediately, though.
from apca.
Your branch works great!
from apca.
Awesome. Thanks for trying it out.
from apca.
Change got merged into master
now.
from apca.
Related Issues (20)
- Standardize DateTime creation for tests HOT 1
- Create a mock test client? HOT 2
- Investigate response headers in relation to rate limiting HOT 6
- Add support for gzip response data HOT 9
- unknown variant ``, expected one of `simple`, `bracket`, `oco`, `oto` HOT 3
- Oauth support? HOT 6
- Hook up portfolio history HOT 3
- support for Latest Multi Trades HOT 1
- Discussion: GPL? HOT 2
- Issue or missunderstanding related to subscriptions. HOT 4
- Calendar date/time. HOT 2
- Tokio using Mio prevents compiling to WASM HOT 1
- UUID using Getrandom and Rand prevents compiling to WASM HOT 1
- Support more Trade properties HOT 11
- Proposal: Use a dedicated data type for stock symbols instead of String HOT 2
- Live trading example not updated HOT 1
- Adding support for crypto streaming HOT 7
- Optionally use rustls instead of hyper-tls HOT 5
- example of streaming data with handlers HOT 3
- Support missing real-time streaming channels HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from apca.