3) I'm planing to fetch prices on a daily basis and write them out as price directives so that if a price source disappears I still have all the previously fetched prices, does that make sense? Any easy way to do this with bean-price? Especially with updated intraday prices where I can't simply append the output of bean-price
1) I specify the price ccy twice, on the one hand in the lookup expression and on the other hand the Source needs to also fill this in when creating the SourcePrice. As far as I can tell only the one from the lookup is used, which makes sense for me as often the source will not know the price ccy. Should this get dropped from SourcePrice?
2) I would like to convert all my prices into a base ccy. Is there any infrastructure around for something like this? I'm not talking about transitive prices, all I would need is to be able to convert a price into my base ccy based on an other conversion. What I'm thinking is something like
* fetch price from Source in USD
* using existing price data convert USD price into CHF
Not really I'm accessing different markets which have different times and some don't have a price every day, so the price date might be a previous day.
On Thursday, November 29, 2018 at 6:49:30 PM UTC+7, Patrick Ruckstuhl wrote:Not really I'm accessing different markets which have different times and some don't have a price every day, so the price date might be a previous day.Sure, I do that, too. I'm still not seeing the problem. Run bean-price and use the price at that time. Why does it matter if you store an intraday price? What do you think happens when you buy or sell something in beancount? The intraday price gets added to the price map. I don't think beancount is really meant for use cases where the difference between the price at 3pm and 4:30pm is material.
Anyway, it is really bothers you to have intraday prices then wait a day, or a week, and then use bean-price to get the prices from 2 or 3 days using the -d parameter once everything is closed & finalized.
Or run bean-price twice a day (or four times a day) and only fetch prices for markets that are closed when you run it.I'm honestly kind of struggling to understand what explicit support you're looking for from bean-price here. Can you elaborate on that a bit? What's the exact usage you envision from beancount?
I would like to have a local price database. I do this with beancount files with price directives. What I'm now looking at is how to update this price files. They basically contain one entry per day and are updated daily. But on a daily run it can return a price date which already exists and I'm looking at a way to update (or maybe ignore) that entry.
Hi,
I'm now mostly done with the price imports. Thanks to the info you guys provided I think I'm able to solve my issues.
Maybe interesting for others could be the way I solved my "prices in base ccy" issue. I'm now going to store the price entries in the ccy as fetched from the price source and then created a very simple plugin, which takes that price, takes the fx rate and creates a new price entry in the base ccy.
Thanks again for the help,
Patrick
--
You received this message because you are subscribed to the Google Groups "Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beancount+...@googlegroups.com.
To post to this group, send email to bean...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/beancount/fd11025b-ded6-481e-bd5c-868c58836e3c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.