--- loncom/interface/statistics/lonproblemstatistics.pm 2005/03/10 17:33:57 1.101 +++ loncom/interface/statistics/lonproblemstatistics.pm 2005/03/14 20:28:22 1.102 @@ -1,6 +1,6 @@ # The LearningOnline Network with CAPA # -# $Id: lonproblemstatistics.pm,v 1.101 2005/03/10 17:33:57 matthew Exp $ +# $Id: lonproblemstatistics.pm,v 1.102 2005/03/14 20:28:22 matthew Exp $ # # Copyright Michigan State University Board of Trustees # @@ -721,11 +721,17 @@ sub BuildProblemStatisticsPage { return; } if (exists($ENV{'form.Excel'})) { + $r->print('

'. + &Apache::lonstatistics::section_and_enrollment_description(). + '

'); &Excel_output($r); } else { $r->print(''.' 'x5); $r->rflush(); + $r->print('

'. + &Apache::lonstatistics::section_and_enrollment_description(). + '

'); my $count = 0; foreach my $seq (@sequences) { my @resources = @@ -1294,9 +1300,9 @@ sub Excel_output { my $sectionstring = ''; $excel_sheet->write($rows_output,$cols_output++, &Apache::lonstathelpers::sections_description - (@Apache::lonstatistics::SelectedSections), + (&Apache::lonstatistics::get_selected_sections()), $format->{'h3'}); - $cols_output += scalar(@Apache::lonstatistics::SelectedSections); + $cols_output += scalar(&Apache::lonstatistics::get_selected_sections()); # # Time restrictions my $time_string; @@ -1537,7 +1543,7 @@ sub get_statistics { my $courseid = $ENV{'request.course.id'}; # my $data = &Apache::loncoursedata::get_problem_statistics - (\@Apache::lonstatistics::SelectedSections, + ([&Apache::lonstatistics::get_selected_sections()], $Apache::lonstatistics::enrollment_status, $symb,$part,$courseid,$starttime,$endtime); $data->{'symb'} = $symb; @@ -1555,7 +1561,7 @@ sub get_statistics { # # Store in metadata if computations were done for all students if ($data->{'num_students'} > 1) { - my @Sections = @Apache::lonstatistics::SelectedSections; + my @Sections = &Apache::lonstatistics::get_selected_sections(); my $sections = '"'.join(' ',@Sections).'"'; $sections =~ s/&+/_/g; # Ensure no special characters $data->{'sections'}=$sections; @@ -1615,7 +1621,7 @@ sub compute_discrimination_factor { my $ranking = &Apache::loncoursedata::rank_students_by_scores_on_resources (\@Resources, - \@Apache::lonstatistics::SelectedSections, + [&Apache::lonstatistics::get_selected_sections()], $Apache::lonstatistics::enrollment_status,undef, $starttime,$endtime); # @@ -1680,7 +1686,7 @@ sub compute_sequence_statistics { # First compute statistics based on student scores my ($smin,$smax,$sMean,$sSTD,$scount,$sMAX) = &Apache::loncoursedata::score_stats - (\@Apache::lonstatistics::SelectedSections, + ([&Apache::lonstatistics::get_selected_sections()], $Apache::lonstatistics::enrollment_status, \@Resources,$starttime,$endtime,undef); $SeqStat{$symb}->{'title'} = $seq->compTitle; @@ -1695,7 +1701,7 @@ sub compute_sequence_statistics { # 'correct' is taken to mean my ($cmin,$cmax,$cMean,$cSTD,$ccount)= &Apache::loncoursedata::count_stats - (\@Apache::lonstatistics::SelectedSections, + ([&Apache::lonstatistics::get_selected_sections()], $Apache::lonstatistics::enrollment_status, \@Resources,$starttime,$endtime,undef); my $K = $part_count;