Re: fixed lot prices
> "TO" == Tavis Ormandy writes: TO> 09-Jan-01 Shell Expenses:Gasoline 11 GAL {=$2.299} 11 GAL {=$2.299} TO> Assets:Checking$-25.29 $-25.29 TO> 11 GAL {=$2.299} TO> TO> Shouldn't it debit the checking account (11 * $2.30) = $25.30, not ($11 * TO> $2.299) = $25.29? Yes, according to the text in the manual it sounds like it should be $25.30. John -- --- You received this message because you are subscribed to the Google Groups "Ledger" group. To unsubscribe from this group and stop receiving emails from it, send an email to ledger-cli+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ledger-cli/m2cyuf1dr1.fsf%40newartisans.com.
Re: fixed lot prices
On 2024-01-03, Tavis Ormandy wrote: > The intention is that if you do bal -X '$', it shows me $100, but only > debits checking $95 on purchase. > I think I figured out a way to do this, here is a solution: = expr (commodity == 'USTBILL') ; VALUE:: $1 2009/01/01 Buy Assets:Broker 100USTBILL @ $0.95 Assets:Checking 2009/02/01 Sell Assets:Broker -100USTBILL {$0.95} [2009/01/01] @ $1 Assets:Checking$100 Income:Capital Gains I don't know if this is the "right" way to record these transactions, but the output makes sense to me? I'm not 100% convinced the fixed lot pricing feature is working as intended... Tavis. -- _o)$ lynx lock.cmpxchg8b.com /\\ _o) _o) $ finger tav...@sdf.org _\_V _( ) _( ) @taviso -- --- You received this message because you are subscribed to the Google Groups "Ledger" group. To unsubscribe from this group and stop receiving emails from it, send an email to ledger-cli+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ledger-cli/un4j22%245s1%241%40ciao.gmane.io.
fixed lot prices
Hello, I'm not sure I understand the Fixed Lot Prices section of the manual: https://ledger-cli.org/doc/ledger3.html#Fixing-Lot-Prices Specifically, this example transaction in section 4.5.3: Expenses:Gasoline 11 GAL {=$2.299} @ $2.30 The manual says "This transaction says that you bought 11 gallons priced at $2.299 per gallon at a cost to you of $2.30 per gallon.". I interpret that to mean I paid $2.30 per gallon, but the gas is worth $2.299 per gallon, but that's not what happens: $ ledger --file fixedlot.ldg reg 09-Jan-01 Shell Expenses:Gasoline 11 GAL {=$2.299} 11 GAL {=$2.299} Assets:Checking$-25.29 $-25.29 11 GAL {=$2.299} Shouldn't it debit the checking account (11 * $2.30) = $25.30, not ($11 * $2.299) = $25.29? I don't care about gas, but I thought this might be an interesting way to represent treasury bills you intend to hold to maturity. These are sold at a discount, i.e. a treasury bill with a face value of $100 might be sold for $95, so you could write this: 2024/01/01 Investment Assets:Broker 100 USTBILL {=$1} @ $0.95 Assets:Checking The intention is that if you do bal -X '$', it shows me $100, but only debits checking $95 on purchase. I dunno if that makes sense, I'm not a finance guy, maybe I'm doing this the naive way! How do other people represent them? :) Tavis. -- _o)$ lynx lock.cmpxchg8b.com /\\ _o) _o) $ finger tav...@sdf.org _\_V _( ) _( ) @taviso -- --- You received this message because you are subscribed to the Google Groups "Ledger" group. To unsubscribe from this group and stop receiving emails from it, send an email to ledger-cli+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ledger-cli/un4dq4%2417i3%241%40ciao.gmane.io.