- We want the top payout per share for dividend returns.
- As noted in discussion on the API Discussion board, Dividends is purely based on the users Outstanding Shares. This makes sense because it shows that it's based on what's owned and not what's been available.
- Based on the available api post calls currently available the only way to get what we want is to:
- Grab the amount paid out from the 100 top dividend payouts using the leaders/dividends list.
- Using the top 100 list, grab each of the user tickers.
- With the tickers, use the Profiles/Info api post to grab each user's outstanding shares.
- Once we had those two pieces of data we divide dividend amount by outstanding shares to get our value.
- Right?
I'll use Fray (Pooka) Close's payout as an example:
- According to data pulled from the api Pooka paid out a total of 3823.75.
- At the present moment, because it does fluctuate, she has 6278 out standing shares.
- With that in mind, I should've made roughly 0.6082 credits per share I own.
- I own 38 shares in Pooka, so in all I should've gotten roughly 23 shares paid out.
- What did I really get? 0.884 credit. What gives?
Truth is, the flaw is in my reading skills. Apparently I missed the fact that /leaders/dividends is a weekly value. That meant that I still had to divide that value by seven.
This is starting to sound less accurate, isn't it? That's the problem. Our dividend information isn't updated. How are you supposed to figure out the best dividend pay outs if you only have a weekly average. Considering how subjective stock is and how much it can change over the course of a day or two. That number could've easily been paid out in large sums at the start of the week and by the end of it basic pennies.
Ruined. There was nothing we could do but wait...and plan. We sat down and for a second time and started to devise an understanding of what we needed and wanted to do with the data. If and when they ever released what we wanted to actually work with was secondary to the discussion. The problem was that with the exponential growth of the site, being able to pump out that much data and then play with it was to say the least, cumbersome. We figured the best way to to get what we wanted to was to hope that they'd put search parameter requirements into the request that would return a limited number of results. That would at least give us the opportunity to work with a limited list of tickers that fit the exact criteria we wanted.
I was also able to explain to Arturo the benefits of oAuth and how it could easily get tied into our larger plan. How it would allow us to garner trust from our users without having to actually ask for credentials from them. That we would then be able to use their own personal data for things like approved notification of certain filtered market alerts. In short, it meant a bunch of stuff for what we wanted to do with this all.
That's sort of where we've been for the last week, stranded. I've optimized some of the code (aka cleaned and moved around) but much more than that, we just wait for Empire Avenue to release new api strings.
No comments:
Post a Comment