summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCraig Earls <enderw88@gmail.com>2011-10-22 07:09:18 -0700
committerCraig Earls <enderw88@gmail.com>2011-10-22 07:09:18 -0700
commit071d23d821c680880e873752d37df980d173d355 (patch)
treed10dcac737d53889565b2c1ed66dbed6da3a58d9
parent884e55afca26f6d1e7cfe8f63e29b1621582dbd3 (diff)
downloadfork-ledger-071d23d821c680880e873752d37df980d173d355.tar.gz
fork-ledger-071d23d821c680880e873752d37df980d173d355.tar.bz2
fork-ledger-071d23d821c680880e873752d37df980d173d355.zip
fixed bug 555, stats now properly reports postings per day
-rw-r--r--doc/ledger3.texi12
-rw-r--r--src/stats.cc4
2 files changed, 9 insertions, 7 deletions
diff --git a/doc/ledger3.texi b/doc/ledger3.texi
index b376840c..922e683c 100644
--- a/doc/ledger3.texi
+++ b/doc/ledger3.texi
@@ -45,7 +45,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
@titlepage
@title Ledger: Command-Line Accounting
@subtitle For Version 3.0 of Ledger
-@subtitle Draft Manual Time-stamp: <2011-10-19 20:36 (cpearls)>
+@subtitle Draft Manual Time-stamp: <2011-10-21 21:33 (cpearls)>
@author John Wiegley
@end titlepage
@@ -3050,6 +3050,8 @@ weekly last august
* equity::
* prices::
* xact::
+* payees::
+* accounts::
@end menu
@node balance, register, Basic Reporting Commands, Basic Reporting Commands
@@ -3150,7 +3152,7 @@ There is also a @command{pricedb} command which outputs the same
information as @command{prices}, but does in a format that can be
parsed by Ledger.
-@node xact, , prices, Basic Reporting Commands
+@node xact, payees, prices, Basic Reporting Commands
@section xact
The @command{xact} commands simplifies the creation of new transactions.
@@ -3206,11 +3208,11 @@ ledger xact 4/9 viva food $11.50 tips $8 cash
ledger xact 4/9 viva dining "DM 11.50"
@end smallexample
-@node payees
+@node payees, accounts, xact, Basic Reporting Commands
@section payees
-The @command{payees} reports all of the unique payees in the journal
+The @command{payees} reports all of the unique payees in the journal.
-@node accounts
+@node accounts, , payees, Basic Reporting Commands
@section accounts
The @command{accounts} reports all of the accounts in the journal.
diff --git a/src/stats.cc b/src/stats.cc
index 172971aa..8899ddf5 100644
--- a/src/stats.cc
+++ b/src/stats.cc
@@ -88,8 +88,8 @@ value_t report_statistics(call_scope_t& args)
out << " (";
out.precision(2);
- out << (double((statistics.latest_post - statistics.earliest_post).days()) /
- double(statistics.posts_count)) << _(" per day)") << std::endl;
+ out << (double(statistics.posts_count)/
+ double((statistics.latest_post - statistics.earliest_post).days())) << _(" per day)") << std::endl;
out << _(" Uncleared postings: ");
out.width(6);