Something further I wanted to note about Ledger 3.0:
1. Any amount or cost expression surrounded by parentheses is a value
expression:
Expenses:Food ($10 + $3)
2. Every value expression has an "evaluation context". For a regular
posting, the context is its own self:
Expenses:Food (amount + $3) ; error, amount has no value
3. For an *automated* posting, the context is the posting that matched:
Expenses:Food (amount + $10) @ (cost + $10)
This means that within any automated posting, you have full access to the
posting that triggered it, allowing for much more complicated amount and cost
expressions than the simple "multiplied by" which is inferred when there are no
commodities in the amount.
John