--- loncom/interface/statistics/lonproblemanalysis.pm 2004/03/16 16:41:26 1.81 +++ loncom/interface/statistics/lonproblemanalysis.pm 2004/04/01 15:32:06 1.84 @@ -1,6 +1,6 @@ # The LearningOnline Network with CAPA # -# $Id: lonproblemanalysis.pm,v 1.81 2004/03/16 16:41:26 matthew Exp $ +# $Id: lonproblemanalysis.pm,v 1.84 2004/04/01 15:32:06 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -160,8 +160,17 @@ sub BuildProblemAnalysisPage { $ProblemData, \@Students); } elsif ($current_problem->{'resptype'} eq 'numerical') { - &NumericalResponseAnalysis($r,$current_problem, - $ProblemData,\@Students); + ## + ## analyze all responses of a problem at once + my $res = $current_problem->{'resource'}; + foreach my $partid (@{$res->{'parts'}}) { + $current_problem->{'part'} = $partid; + foreach my $respid (@{$res->{'partdata'}->{$partid}->{'ResponseIds'}}) { + $current_problem->{'respid'}=$respid; + &NumericalResponseAnalysis($r,$current_problem, + $ProblemData,\@Students); + } + } } else { $r->print('