Simulating average cost booking seems like a good way to do this as well. 
If I do not include the {} on the Old account though I end up with -30 AAPL 
similar to the result in example 1. Adding the lost selector solves this 
though. 

Glad it helped! As you already mentioned, the underlying concepts of how 
lot matching is done or not are a good idea to understand. In addition, how 
those concepts are exercised based on your Beancount transaction syntax 
would be very helpful. The good thing is, documentation for all those 
things is excellent with Beancount.

With STRICT booking, if you augment (buy) 30 AAPL, then reduce (sell) -20 
AAPL, the reduction will have to to be matched to the existing 30, and will 
specifically reduce 20 out of the 30.

With NONE booking, if you do the same augment and reduction, then see this 
doc 
<https://beancount.github.io/docs/how_inventories_work.html#strict-booking>:
​

No Booking 
<https://beancount.github.io/docs/how_inventories_work.html#no-booking>

However, there is another way to deal with non-taxable accounts in the 
meantime: you can simply disable the booking. There is a booking method 
called “*NONE*” which implements a very liberal strategy which accepts any 
new lot.. New lots are always appended unconditionally to the inventory. 
Using this strategy on the transactions from the previous section would 
result in this inventory:
units ccy cost cost-ccy lot-date label 45.0045 VBMPX {11.11 USD, 
2016-07-28, None} 54.5951 VBMPX {10.99 USD, 2016-10-12, None} -1.4154 VBMPX 
{10.59 USD, 2016-12-30, None} 

Observe how the resulting inventory has a mix of signs; normally this is 
not allowed, but it is tolerated under this degenerate booking method. Note 
that under this method, the only meaningful values are the *total* number 
of units and the *total* or *average* cost amounts. The individual lots 
aren’t really lots, they only represent the list of all postings made to 
that account.

-- 
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 [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/beancount/08a109ab-e93c-4835-9d6e-b342d370bfccn%40googlegroups.com.

Reply via email to