[LON-CAPA-cvs] cvs: loncom(version_2_11_X) /interface/statistics lonproblemstatistics.pm

raeburn raeburn at source.lon-capa.org
Wed Mar 7 08:32:56 EST 2018


raeburn		Wed Mar  7 13:32:56 2018 EDT

  Modified files:              (Branch: version_2_11_X)
    /loncom/interface/statistics	lonproblemstatistics.pm 
  Log:
  - For 2.11
    - Backport 1.128.
  
  
Index: loncom/interface/statistics/lonproblemstatistics.pm
diff -u loncom/interface/statistics/lonproblemstatistics.pm:1.122.2.3 loncom/interface/statistics/lonproblemstatistics.pm:1.122.2.4
--- loncom/interface/statistics/lonproblemstatistics.pm:1.122.2.3	Mon Mar  3 20:45:05 2014
+++ loncom/interface/statistics/lonproblemstatistics.pm	Wed Mar  7 13:32:56 2018
@@ -1,6 +1,6 @@
 # The LearningOnline Network with CAPA
 #
-# $Id: lonproblemstatistics.pm,v 1.122.2.3 2014/03/03 20:45:05 raeburn Exp $
+# $Id: lonproblemstatistics.pm,v 1.122.2.4 2018/03/07 13:32:56 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1667,11 +1667,11 @@
     my $number_to_grab = int(scalar(@{$ranking})/4);
     my $num_students = scalar(@{$ranking});
     my @BottomSet = map { $_->[&Apache::loncoursedata::RNK_student()];
-                      } @{$ranking}[0..$number_to_grab];
+                      } @{$ranking}[0..$number_to_grab-1];
     my @TopSet    =
         map {
             $_->[&Apache::loncoursedata::RNK_student()];
-          } @{$ranking}[-$number_to_grab..0];
+          } @{$ranking}[-$number_to_grab..-1];
     if (! @BottomSet || (@BottomSet == 1 && $BottomSet[0] eq '') ||
         ! @TopSet    || (@TopSet    == 1 && $TopSet[0]    eq '')) {
         return 'nan';




More information about the LON-CAPA-cvs mailing list