Questions about the statistics system
May. 8th, 2010 01:26 pm![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Hi all! I'm getting ready to start my GSoC project on Usage and Business Statistics, and I'm just starting to realize how much stuff I don't know! I hope this is the right place to post some questions about the statistics system:
1. How can I use the stats system modules in a perl script? I would like to write a simple script like this as a way of learning about how the stats system works:
--------------
use DW::StatStore;
use DW::StatData;
use DW::StatData::AccountsByType;
my $accounts_by_type = DW::StatData::AccountsByType->load_latest( DW::StatStore->get( "accounts" ) );
# MORE CODE...
--------------
but if I do this within my Dreamhack perl complains that it can't find the modules I asked it to use (even though exactly the same code works fine within /stats/site.bml!) I've tried adding an absolute path to the modules, but it turns out that these depend on a bunch of LJ modules which I can't find.
2. How can I get my Dreamhack to display /admin/stats.bml? (This is only displayed to users with admin priviledges).
3. What are 'crumbs'? I've seen this word in a couple of places, and I've no idea what it is.
4. Just to check, is it the case that if I'm editing a BML page, I should convert it to Template Toolkit?
5. /stats.bml uses the old legacy stats system - is it going to be replaced, or left as it is? If it's going to stay, should I add graphs to it (i.e. display the info on this page in graph form - apart from Age Distribution, which already has a graph)?.
1. How can I use the stats system modules in a perl script? I would like to write a simple script like this as a way of learning about how the stats system works:
--------------
use DW::StatStore;
use DW::StatData;
use DW::StatData::AccountsByType;
my $accounts_by_type = DW::StatData::AccountsByType->load_latest( DW::StatStore->get( "accounts" ) );
# MORE CODE...
--------------
but if I do this within my Dreamhack perl complains that it can't find the modules I asked it to use (even though exactly the same code works fine within /stats/site.bml!) I've tried adding an absolute path to the modules, but it turns out that these depend on a bunch of LJ modules which I can't find.
2. How can I get my Dreamhack to display /admin/stats.bml? (This is only displayed to users with admin priviledges).
3. What are 'crumbs'? I've seen this word in a couple of places, and I've no idea what it is.
4. Just to check, is it the case that if I'm editing a BML page, I should convert it to Template Toolkit?
5. /stats.bml uses the old legacy stats system - is it going to be replaced, or left as it is? If it's going to stay, should I add graphs to it (i.e. display the info on this page in graph form - apart from Age Distribution, which already has a graph)?.