On Thursday, March 15, 2012 7:40:33 AM UTC-7, enderw88 wrote:
>
> Yes. Here is the entire call to Ledger is use:
>
> ledger bal Allocation --current --format "\
> | %-20((depth_spacer)+(partial_account))\
> %10(percent(market(display_total), market(parent.total)))\
> %16(market(display_total)) |\n%/\
> +------------------------------------------------+
> "
Ah, your call is *not* producing a total at the end. What I was
missing from *my* attempt to use that string was the trailing
'%/' at the end of your example. So using the trailing '%/' appears
to suppress the total and side-steps the problem.
$ ledger bal Allocation --current --format "\
%-20((depth_spacer)+(partial_account))\
%10(percent(market(display_total), market(parent.total)))\
%16(market(display_total))\n%/"
Allocation 100.00% $844,219.57
Equities 72.70% $613,725.18
International 39.69% $243,571.94
United States 60.31% $370,153.24
Fixed Income 19.82% $167,325.27
Bonds 19.01% $31,811.43
Cash 12.38% $20,718.41
Inflation Linked Bonds 68.61% $114,795.43
Other 0.38% $3,182.46
Real Estate 7.11% $59,986.66
$ ledger bal Allocation --current --format "\
%-20((depth_spacer)+(partial_account))\
%10(percent(market(display_total), market(parent.total)))\
%16(market(display_total))\n"
While calculating format expression:
percent(market(display_total), market((parent.total)))
While evaluating value expression:
percent(market(display_total), market((parent.total)))
^^^^^^^^^^^^^^
While calling function 'market <#EXPR (parent.total)>':
While calling function 'percent (<#EXPR market(display_total)>, <#EXPR
market((parent.total))>)':
Error: Left operand does not evaluate to an object