--- loncom/interface/statistics/lonproblemstatistics.pm 2003/08/29 21:11:25 1.57
+++ loncom/interface/statistics/lonproblemstatistics.pm 2004/03/07 21:42:19 1.70
@@ -1,6 +1,6 @@
# The LearningOnline Network with CAPA
#
-# $Id: lonproblemstatistics.pm,v 1.57 2003/08/29 21:11:25 matthew Exp $
+# $Id: lonproblemstatistics.pm,v 1.70 2004/03/07 21:42:19 matthew Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -51,11 +51,21 @@ package Apache::lonproblemstatistics;
use strict;
use Apache::lonnet();
+use Apache::loncommon();
use Apache::lonhtmlcommon;
use Apache::loncoursedata;
use Apache::lonstatistics;
+use Apache::lonlocal;
use Spreadsheet::WriteExcel;
+use Apache::lonstathelpers();
+##
+## Localization notes:
+##
+## in @Fields[0]->{'long_title'} is placed in Excel files and is used as the
+## header for plots created with Graph.pm, both of which more than likely do
+## not support localization.
+##
my @Fields = (
{ name => 'problem_num',
title => 'P#',
@@ -138,7 +148,7 @@ my @Fields = (
title => '#YES',
align => 'right',
color => '#FFDDDD',
- format => '%d',
+ format => '%4.1f',# format => '%d',
sortable => 'yes',
graphable => 'yes',
long_title => 'Number of Students able to Solve' },
@@ -146,7 +156,7 @@ my @Fields = (
title => '#yes',
align => 'right',
color => '#FFDDDD',
- format => '%d',
+ format => '%4.1f',# format => '%d',
sortable => 'yes',
graphable => 'yes',
long_title => 'Number of Students given Override' },
@@ -176,19 +186,19 @@ select sections, maps, and output.
###############################################
my @OutputOptions =
(
- { name => 'problem statistics grouped by sequence',
+ { name => 'grouped by sequence',
value => 'HTML problem statistics grouped',
description => 'Output statistics for the problem parts.',
mode => 'html',
show => 'grouped',
},
- { name => 'problem statistics ungrouped',
+ { name => 'ungrouped',
value => 'HTML problem statistics ungrouped',
description => 'Output statistics for the problem parts.',
mode => 'html',
show => 'ungrouped',
},
- { name => 'problem statistics, Excel',
+ { name => 'Excel',
value => 'Excel problem statistics',
description => 'Output statistics for the problem parts '.
'in an Excel workbook',
@@ -199,12 +209,16 @@ my @OutputOptions =
sub CreateInterface {
my $Str = '';
+ $Str .= &Apache::lonhtmlcommon::breadcrumbs
+ (undef,'Overall Problem Statistics','Statistics_Overall_Key');
$Str .= '
");
+ my ($starttime,$endtime) = &Apache::lonstathelpers::get_time_limits();
+ if (defined($starttime) || defined($endtime)) {
+ # Inform the user what the time limits on the data are.
+ $r->print('
'.&mt('Statistics on submissions from [_1] to [_2]',
+ &Apache::lonlocal::locallocaltime($starttime),
+ &Apache::lonlocal::locallocaltime($endtime)).
+ '
');
+ }
+ $r->print("
".&mt('Compiled on [_1]',
+ &Apache::lonlocal::locallocaltime(time))."