Exporting Anki Statistics

The statistics for your decks are stored, like everything else the SQLite database which composes your deck. While you can view a rich assortment of this data by opening Anki and viewing the deck statistics or the graphs, using an SQLite browser, or directly via the command line, you may wish to export statistics related to your study.

Where the Statistics Are Kept

Anki keeps statistics in several places in its SQL tables, but the "stats" table has a record for every day you studied at least one session in Anki with the deck. This record stores, among other things: the date ('day'), the number of cards you have studied, or more accurately the total number of repetitions ('reps'), and the total number of minutes you studied ('reviewTime').

The "decks" table also includes a number of useful statistics about your deck, including: how many total facts your deck has ('factCount'), how many total cards there are in the deck ('cardCount'), how many cards are currently due ('revCount'), and how many cards have not ever been studied ('newCount').

Exporting Statistics to a Text File

Konrad M. Lawson has written a very rudimentary open source Ruby hack to export certain useful study statistics from your Anki deck or decks to a text file log for each deck at a location specified by you. Should work with Mac OS X and Linux with ruby installed.

http://sites.huginn.net/scripts/script-list

You can set this, for example, to run once per day using cron or launchd, and thus keep a daily log, in a simple text file form, of your daily progress. It lists how many cards are still unseen, total facts and cards, total cards and time studied today, and days since the deck was last studied.

AnkiWiki: ExportingAnkiStatistics (last edited 2009-11-08 06:22:20 by kmlawson)