version 1.114, 2005/02/22 22:51:16
|
version 1.117, 2005/03/11 21:14:41
|
Line 97 sub BuildProblemAnalysisPage {
|
Line 97 sub BuildProblemAnalysisPage {
|
$r->print($html.(' 'x5)); |
$r->print($html.(' 'x5)); |
} |
} |
# |
# |
|
$r->print(&Apache::lonstathelpers::submission_report_form |
|
('problem_analysis')); |
|
# |
$r->print('<hr />'); |
$r->print('<hr />'); |
$r->rflush(); |
$r->rflush(); |
# |
# |
Line 104 sub BuildProblemAnalysisPage {
|
Line 107 sub BuildProblemAnalysisPage {
|
my $current_problem = &Apache::lonstathelpers::get_target_from_id |
my $current_problem = &Apache::lonstathelpers::get_target_from_id |
($ENV{'form.problemchoice'}); |
($ENV{'form.problemchoice'}); |
# |
# |
my ($prev,$curr,$next) = |
my ($navmap,$prev,$curr,$next) = |
&Apache::lonstathelpers::get_prev_curr_next($current_problem, |
&Apache::lonstathelpers::get_prev_curr_next($current_problem, |
$problem_types, |
$problem_types, |
'response', |
'response', |
Line 127 sub BuildProblemAnalysisPage {
|
Line 130 sub BuildProblemAnalysisPage {
|
$r->print('resource is undefined'); |
$r->print('resource is undefined'); |
} else { |
} else { |
my $resource = $current_problem->{'resource'}; |
my $resource = $current_problem->{'resource'}; |
$r->print('<h1>'.$resource->{'title'}.'</h1>'); |
$r->print('<h1>'.$resource->compTitle.'</h1>'); |
$r->print('<h3>'.$resource->{'src'}.'</h3>'); |
$r->print('<h3>'.$resource->src.'</h3>'); |
if ($ENV{'form.show_prob'} eq 'true') { |
if ($ENV{'form.show_prob'} eq 'true') { |
$r->print(&Apache::lonstathelpers::render_resource($resource)); |
$r->print(&Apache::lonstathelpers::render_resource($resource)); |
} |
} |
$r->rflush(); |
$r->rflush(); |
my %Data = &Apache::lonstathelpers::get_problem_data |
my %Data = &Apache::lonstathelpers::get_problem_data |
($resource->{'src'}); |
($resource->src); |
my $problem_data = $Data{$current_problem->{'part'}. |
my $problem_data = $Data{$current_problem->{'part'}. |
'.'. |
'.'. |
$current_problem->{'respid'}}; |
$current_problem->{'respid'}}; |
Line 159 sub BuildProblemAnalysisPage {
|
Line 162 sub BuildProblemAnalysisPage {
|
&mt('Analyze Problem').'" />'); |
&mt('Analyze Problem').'" />'); |
$r->print(' 'x5); |
$r->print(' 'x5); |
$r->print('<h3>'.&mt('Please select a problem to analyze').'</h3>'); |
$r->print('<h3>'.&mt('Please select a problem to analyze').'</h3>'); |
$r->print(&Apache::lonstathelpers::ProblemSelector |
$r->print(&Apache::lonstathelpers::problem_selector($problem_types)); |
($problem_types)); |
|
} |
} |
} |
} |
|
|
Line 186 sub numerical_response_analysis {
|
Line 188 sub numerical_response_analysis {
|
my $response_data = &Apache::loncoursedata::get_response_data |
my $response_data = &Apache::loncoursedata::get_response_data |
(\@Apache::lonstatistics::SelectedSections, |
(\@Apache::lonstatistics::SelectedSections, |
$Apache::lonstatistics::enrollment_status, |
$Apache::lonstatistics::enrollment_status, |
$resource->{'symb'},$respid); |
$resource->symb,$respid); |
# |
# |
$problem_analysis->{'answercomputed'} = 1; |
$problem_analysis->{'answercomputed'} = 1; |
if ($problem_analysis->{'answercomputed'}) { |
if ($problem_analysis->{'answercomputed'}) { |
Line 765 sub radio_response_analysis {
|
Line 767 sub radio_response_analysis {
|
my $response_data = &Apache::loncoursedata::get_response_data |
my $response_data = &Apache::loncoursedata::get_response_data |
(\@Apache::lonstatistics::SelectedSections, |
(\@Apache::lonstatistics::SelectedSections, |
$Apache::lonstatistics::enrollment_status, |
$Apache::lonstatistics::enrollment_status, |
$resource->{'symb'},$respid); |
$resource->symb,$respid); |
my $correct; # either a hash reference or a scalar |
my $correct; # either a hash reference or a scalar |
if ($problem_analysis->{'answercomputed'} || scalar(@$concepts) > 1) { |
if ($problem_analysis->{'answercomputed'} || scalar(@$concepts) > 1) { |
# This takes a while for large classes... |
# This takes a while for large classes... |
Line 1172 sub OptionResponseAnalysis {
|
Line 1174 sub OptionResponseAnalysis {
|
my $PerformanceData = &Apache::loncoursedata::get_response_data |
my $PerformanceData = &Apache::loncoursedata::get_response_data |
(\@Apache::lonstatistics::SelectedSections, |
(\@Apache::lonstatistics::SelectedSections, |
$Apache::lonstatistics::enrollment_status, |
$Apache::lonstatistics::enrollment_status, |
$resource->{'symb'},$respid); |
$resource->symb,$respid); |
if (! defined($PerformanceData) || |
if (! defined($PerformanceData) || |
ref($PerformanceData) ne 'ARRAY' ) { |
ref($PerformanceData) ne 'ARRAY' ) { |
$r->print('<h2>'. |
$r->print('<h2>'. |
Line 1306 sub OR_tries_analysis {
|
Line 1308 sub OR_tries_analysis {
|
# Create Foil Plots |
# Create Foil Plots |
my $data_count = $response_data{'_total'}->[$try]; |
my $data_count = $response_data{'_total'}->[$try]; |
my $correct = $response_data{'_correct'}->[$try]; |
my $correct = $response_data{'_correct'}->[$try]; |
|
if (! defined($correct)) { $correct = 0; } |
my @Datasets; |
my @Datasets; |
foreach my $option ('_correct',@{$ORdata->{'_Options'}}) { |
foreach my $option ('_correct',@{$ORdata->{'_Options'}}) { |
next if (! exists($foil_plot[$try]->{$option})); |
next if (! exists($foil_plot[$try]->{$option})); |
Line 1811 sub CreateInterface {
|
Line 1814 sub CreateInterface {
|
$Str .= '<tr>'; |
$Str .= '<tr>'; |
$Str .= '<td align="center"><b>'.&mt('Sections').'</b></td>'; |
$Str .= '<td align="center"><b>'.&mt('Sections').'</b></td>'; |
$Str .= '<td align="center"><b>'.&mt('Enrollment Status').'</b></td>'; |
$Str .= '<td align="center"><b>'.&mt('Enrollment Status').'</b></td>'; |
# $Str .= '<td align="center"><b>'.&mt('Sequences and Folders').'</b></td>'; |
|
$Str .= '<td align="center"> </td>'; |
$Str .= '<td align="center"> </td>'; |
$Str .= '</tr>'."\n"; |
$Str .= '</tr>'."\n"; |
## |
## |
Line 1824 sub CreateInterface {
|
Line 1826 sub CreateInterface {
|
$Str .= &Apache::lonhtmlcommon::StatusOptions(undef,undef,5); |
$Str .= &Apache::lonhtmlcommon::StatusOptions(undef,undef,5); |
$Str .= '</td>'; |
$Str .= '</td>'; |
# |
# |
# $Str .= '<td align="center">'; |
|
my $only_seq_with_assessments = sub { |
|
my $s=shift; |
|
if ($s->{'num_assess'} < 1) { |
|
return 0; |
|
} else { |
|
return 1; |
|
} |
|
}; |
|
&Apache::lonstatistics::MapSelect('Maps','multiple,all',5, |
|
$only_seq_with_assessments); |
|
## |
## |
## |
## |
$Str .= '<td>'; |
$Str .= '<td>'; |