'.
&mt('The analysis you have selected is not supported at this time').
@@ -225,7 +221,6 @@ sub RadioResponseAnalysis {
$r->print($analysis_html);
}
-
sub RR_Excel_output {
my ($r,$PerformanceData,$ProblemData) = @_;
return '
No!
';
@@ -246,15 +241,15 @@ sub RR_Tries_Analysis {
}
$analysis_html .= $table;
my @TryData = &RR_tries_data_analysis($r,$PerformanceData);
- if ($ENV{'form.AnalyzeAs'} eq 'Foils') {
- $analysis_html = &RR_Tries_Foil_Analysis($mintries,$maxtries,$Foils,
+# if ($ENV{'form.AnalyzeAs'} eq 'Foils') {
+ $analysis_html .= &RR_Tries_Foil_Analysis($mintries,$maxtries,$Foils,
\@TryData,$ProblemData);
- } else {
- $analysis_html = &RR_Tries_Concept_Analysis($mintries,$maxtries,
- $Concepts,
- \@TryData,
- $ProblemData);
- }
+# } else {
+# $analysis_html = &RR_Tries_Concept_Analysis($mintries,$maxtries,
+# $Concepts,
+# \@TryData,
+# $ProblemData);
+# }
return $analysis_html;
}
@@ -284,8 +279,8 @@ sub RR_Tries_Foil_Analysis {
my @PlotData_Correct;
my @PlotData_Incorrect;
next if ($try > scalar(@{$TryData}));
- next if (! defined($TryData->[$try-1]));
- my %DataSet = %{$TryData->[$try-1]};
+ next if (! defined($TryData->[$try]));
+ my %DataSet = %{$TryData->[$try]};
my $total = 0;
foreach my $foilid (@$Foils) {
$total += $DataSet{$foilid};
@@ -316,7 +311,6 @@ sub RR_Tries_Foil_Analysis {
\@PlotData_Correct,
\@PlotData_Incorrect);
}
- &Apache::lonnet::logthis('plot = '.$html);
return $html;
}
@@ -339,14 +333,12 @@ sub RR_Time_Concept_Analysis {
}
-
sub get_Radio_problem_data {
my ($url) = @_;
my $Answ=&Apache::lonnet::ssi($url,('grade_target' => 'analyze'));
(my $garbage,$Answ)=split('_HASH_REF__',$Answ,2);
my %Answer = &Apache::lonnet::str2hash($Answ);
my %Partdata;
- &Apache::lonnet::logthis('url = '.$url);
foreach my $part (@{$Answer{'parts'}}) {
while (my($key,$value) = each(%Answer)) {
# if (ref($value) eq 'ARRAY') {
@@ -372,9 +364,6 @@ sub get_Radio_problem_data {
return %Partdata;
}
-=cut
-
-
#########################################################
#########################################################
##
@@ -383,7 +372,10 @@ sub get_Radio_problem_data {
#########################################################
#########################################################
sub OptionResponseAnalysis {
- my ($r,$resource,$respid,$ProblemData,$Students) = @_;
+ my ($r,$problem,$ProblemData,$Students) = @_;
+ my ($resource,$respid) = ($problem->{'resource'},
+ $problem->{'respid'});
+ # Note: part data is not needed.
my $PerformanceData =
&Apache::loncoursedata::get_response_data
($Students,$resource->{'symb'},$respid);
@@ -1517,8 +1509,8 @@ sub ProblemSelector {
for (my $i=0;$i{'ResponseTypes'}});$i++){
my $respid = $partdata->{'ResponseIds'}->[$i];
my $resptype = $partdata->{'ResponseTypes'}->[$i];
- if ($resptype eq 'option' ){
-# if ($resptype eq 'option' || $resptype eq 'radiobutton') {
+# if ($resptype eq 'option' ){
+ if ($resptype eq 'option' || $resptype eq 'radiobutton') {
my $value = &make_target_id({symb=>$res->{'symb'},
part=>$part,
respid=>$respid,
@@ -1533,7 +1525,8 @@ sub ProblemSelector {
}
$seq_str .= '
'.
''.
- '
'.
+ '
'.
+#.$resptype.'
'.
''.$title.' ';
# ''.$resptype.' '.$res->{'title'}.' ';
if ($partdata->{'option'} > 1) {
@@ -1594,7 +1587,8 @@ sub get_prev_curr_next {
for (my $i=0;$i{'ResponseTypes'}});$i++){
my $respid = $partdata->{'ResponseIds'}->[$i];
my $resptype = $partdata->{'ResponseTypes'}->[$i];
- next if ($resptype ne 'option');
+ next if ($resptype ne 'option' &&
+ $resptype ne 'radiobutton');
push (@Resource,
{ symb => $res->{symb},
part => $part,