Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Daily price change #3

Open
jennazenk opened this issue Oct 30, 2019 · 1 comment
Open

Daily price change #3

jennazenk opened this issue Oct 30, 2019 · 1 comment

Comments

@jennazenk
Copy link

Daily price change at time N should only be calculated with share price at N-1 price update and share price at N price update

@iherger
Copy link
Collaborator

iherger commented Oct 31, 2019

In the subgraph, price updates for funds can have different sources: the priceUpdate event, trading events, and investment events. However, we currently don't track the source of the price update in the melon subgraph.

I have deployed a short term fix to the frontend, which does the following:

  • the share price change shown is still the price change between the last two price updates (of any kind, because we currently have no way of telling where a price update comes from)
  • the share price change is not extrapolated to a daily value to prevent spikes when trades happen in quick succession (the regular price update happens quite regular now, almost daily, so that's still fine).

I am also adding a tracking field to the price update data in the melon subgraph, so that we know what the source of each price update is, and that we can change the share price change function to the daily price update changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants