diff --git a/lib/DBD/SQLite.pm b/lib/DBD/SQLite.pm index b7842bd..deafc16 100644 --- a/lib/DBD/SQLite.pm +++ b/lib/DBD/SQLite.pm @@ -1522,7 +1522,7 @@ Here is a simple aggregate function which returns the variance my $sigma = 0; foreach my $v ( @$self ) { - $sigma += ($x - $mu)**2; + $sigma += ($v - $mu)**2; } $sigma = $sigma / ($n - 1);