'.
''.
@@ -1092,7 +1432,7 @@ sub OR_time_analysis {
&OR_time_process_data($performance_data,$begin_index,$end_index);
##
$table .= ''.
- &mt('[_1] submissions from [_2] students submitting, [_3] correct, [_4] incorrect',
+ &mt('[_1] submissions from [_2] students, [_3] correct, [_4] incorrect',
$data_count,$student_count,$correct,$data_count-$correct).
' | '.$/;
my $concept_correct_plot = '';
@@ -1166,7 +1506,8 @@ sub OR_Foil_Time_Analysis {
100,
$plotcolors,
undef,
- $plotdata[0]);
+ $plotdata[0],
+ {xskip=>1});
for (my $j=0; $j< scalar(@{$plotdata[0]});$j++) {
$plotdata[0]->[$j]=0;
}
@@ -1177,7 +1518,7 @@ sub OR_Foil_Time_Analysis {
100,
$plotcolors,
undef,
- @plotdata);
+ @plotdata,{xskip=>1});
return ($correct_plot,$incorrect_plot);
}
@@ -1208,7 +1549,7 @@ sub OR_Concept_Time_Analysis {
100,
$plotcolors,
undef,
- \@plotdata);
+ \@plotdata,{xskip=>1});
}
sub OR_time_process_data {
@@ -1226,7 +1567,6 @@ sub OR_time_process_data {
if ($end_index == scalar(@$performance_data)-1) {
$end_index++;
}
- &Apache::lonnet::logthis(' '.$begin_index.':'.$end_index);
my $count;
for (my $i=$begin_index;$i<$end_index;$i++) {
my $attempt = $performance_data->[$i];
@@ -1246,7 +1586,6 @@ sub OR_time_process_data {
}
}
}
- &Apache::lonnet::logthis('count = '.$count);
return (\%processed_time_data,$correct,$data_count,
scalar(keys(%distinct_students)));
}
@@ -1258,6 +1597,33 @@ sub OR_time_process_data {
##
#########################################################
#########################################################
+sub build_student_data_worksheet {
+ my ($workbook,$format) = @_;
+ my $rows_output = 3;
+ my $cols_output = 0;
+ my $worksheet = $workbook->addworksheet('Student Data');
+ $worksheet->write($rows_output++,0,'Student Data',$format->{'h3'});
+ my @Headers = ('full name','username','domain','section',
+ "student\nnumber",'identifier');
+ $worksheet->write_row($rows_output++,0,\@Headers,$format->{'header'});
+ my @Students = @Apache::lonstatistics::Students;
+ my $studentrows = &Apache::loncoursedata::get_student_data(\@Students);
+ my %ids;
+ foreach my $row (@$studentrows) {
+ my ($mysqlid,$student) = @$row;
+ $ids{$student}=$mysqlid;
+ }
+ foreach my $student (@Students) {
+ my $name_domain = $student->{'username'}.':'.$student->{'domain'};
+ $worksheet->write_row($rows_output++,0,
+ [$student->{'fullname'},
+ $student->{'username'},$student->{'domain'},
+ $student->{'section'},$student->{'id'},
+ $ids{$name_domain}]);
+ }
+ return $worksheet;
+}
+
sub OR_excel_sheet {
my ($r,$resource,$performance_data,$ORdata) = @_;
my $response = '';
@@ -1408,6 +1774,7 @@ sub OR_build_response_data_worksheet {
my ($foilid,$correct) = split('=',$Foilgrades[$j]);
my (undef,$submission) = split('=',$Foilsubs[$j]);
$submission = &Apache::lonnet::unescape($submission);
+ $foilid = &Apache::lonnet::unescape($foilid);
$response_data{$foilid.' submission'}=$submission;
$response_data{$foilid.' award'}=$correct;
}
|