version 1.76, 2004/03/11 20:06:50
|
version 1.77, 2004/03/11 20:11:18
|
Line 607 sub OR_Tries_Foil_Analysis {
|
Line 607 sub OR_Tries_Foil_Analysis {
|
my $optionkey = &build_option_index($ORdata); |
my $optionkey = &build_option_index($ORdata); |
for (my $try=$mintries;$try<=$maxtries;$try++) { |
for (my $try=$mintries;$try<=$maxtries;$try++) { |
my $count = $ResponseData{'_total'}->[$try]; |
my $count = $ResponseData{'_total'}->[$try]; |
if ($count == 0) { |
my $title = 'Submission '.$try.' (N='.$count.')'; |
$count = 'no submissions'; |
|
} elsif ($count == 1) { |
|
$count = '1 submission'; |
|
} else { |
|
$count = $count.' submissions'; |
|
} |
|
my $title = 'Attempt '.$try.', '.$count; |
|
my @Datasets; |
my @Datasets; |
foreach my $option ('_correct',@{$ORdata->{'_Options'}}) { |
foreach my $option ('_correct',@{$ORdata->{'_Options'}}) { |
next if (! exists($PlotData[$try]->{$option})); |
next if (! exists($PlotData[$try]->{$option})); |
Line 658 sub OR_Tries_Foil_Analysis {
|
Line 651 sub OR_Tries_Foil_Analysis {
|
} |
} |
$count = $ResponseData{'_total'}->[$try] - |
$count = $ResponseData{'_total'}->[$try] - |
$ResponseData{'_correct'}->[$try]; |
$ResponseData{'_correct'}->[$try]; |
if ($count == 0) { |
$title = 'Submission '.$try.' (N='.$count.')'; |
$count = 'no submissions'; |
|
} elsif ($count == 1) { |
|
$count = '1 submission'; |
|
} else { |
|
$count = $count.' submissions'; |
|
} |
|
$title = 'Attempt '.$try.', '.$count; |
|
my $incorrectgraph = &Apache::loncommon::DrawBarGraph |
my $incorrectgraph = &Apache::loncommon::DrawBarGraph |
($title,'Foil Number','% Option Chosen Incorrectly', |
($title,'Foil Number','% Option Chosen Incorrectly', |
100,$plotcolors,\@Labels,@Datasets); |
100,$plotcolors,\@Labels,@Datasets); |