Commits

Bryan O'Sullivan committed ea8afae

Tidy up imports and unused modules.

Comments (0)

Files changed (11)

Statistics/Autocorrelation.hs

     , autocorrelation
     ) where
 
+import Statistics.Sample (Sample, mean)
 import qualified Data.Vector.Unboxed as U
-import Statistics.Sample (Sample, mean)
 
 -- | Compute the autocovariance of a sample, i.e. the covariance of
 -- the sample against a shifted version of itself.

Statistics/Function.hs

 import Control.Exception (assert)
 import Control.Monad.Primitive (PrimMonad)
 import Data.Vector.Algorithms.Combinators (apply)
+import Data.Vector.Generic (unsafeFreeze)
+import qualified Data.Vector.Algorithms.Intro as I
 import qualified Data.Vector.Unboxed as U
-import Data.Vector.Generic (unsafeFreeze)
 import qualified Data.Vector.Unboxed.Mutable  as MU
-import qualified Data.Vector.Algorithms.Intro as I
 
 -- | Sort a vector.
 sort :: (U.Unbox e, Ord e) => U.Vector e -> U.Vector e

Statistics/KernelDensity.hs

     , simplePDF
     ) where
 
-import qualified Data.Vector.Unboxed as U
+import Statistics.Constants (m_1_sqrt_2, m_2_sqrt_pi)
 import Statistics.Function (minMax)
 import Statistics.Sample (stdDev)
-import Statistics.Constants (m_1_sqrt_2, m_2_sqrt_pi)
 import Statistics.Types (Sample)
+import qualified Data.Vector.Unboxed as U
 
 -- | Points from the range of a 'Sample'.
 newtype Points = Points {

Statistics/Math.hs

     -- $references
     ) where
 
-import qualified Data.Vector.Unboxed as U
 import Data.Vector.Unboxed ((!))
 import Data.Word (Word64)
 import Statistics.Constants (m_sqrt_2_pi)
 import Statistics.Distribution (cumulative)
 import Statistics.Distribution.Normal (standard)
+import qualified Data.Vector.Unboxed as U
 
 data C = C {-# UNPACK #-} !Double {-# UNPACK #-} !Double {-# UNPACK #-} !Double
 

Statistics/Quantile.hs

     ) where
 
 import Control.Exception (assert)
-import qualified Data.Vector.Unboxed as U
 import Data.Vector.Unboxed ((!))
 import Statistics.Constants (m_epsilon)
 import Statistics.Function (partialSort)
 import Statistics.Types (Sample)
+import qualified Data.Vector.Unboxed as U
 
 -- | O(/n/ log /n/). Estimate the /k/th /q/-quantile of a sample,
 -- using the weighted average method.

Statistics/RandomVariate.hs

-module Statistics.RandomVariate
-    (
-      module System.Random.MWC
-    ) where
-
-import System.Random.MWC

Statistics/Resampling.hs

 
 import Control.Monad (forM_, liftM)
 import Control.Monad.Primitive (PrimMonad, PrimState)
+import Data.Vector.Algorithms.Intro (sort)
+import Data.Vector.Generic (unsafeFreeze)
+import Data.Vector.Unboxed ((!))
+import Statistics.Function (create, indexed, indices)
+import Statistics.Types (Estimator, Sample)
+import System.Random.MWC (Gen, uniform)
 import qualified Data.Vector.Unboxed as U
 import qualified Data.Vector.Unboxed.Mutable as MU
-import Data.Vector.Unboxed ((!))
-import Data.Vector.Generic (unsafeFreeze)
-import Data.Vector.Algorithms.Intro (sort)
-import Statistics.Function (create, indexed, indices)
-import System.Random.MWC (Gen, uniform)
-import Statistics.Types (Estimator, Sample)
 
 -- | A resample drawn randomly, with replacement, from a set of data
 -- points.  Distinct from a normal array to make it harder for your

Statistics/Resampling/Bootstrap.hs

     ) where
 
 import Control.Exception (assert)
-import qualified Data.Vector.Unboxed as U
 import Data.Vector.Unboxed ((!))
+import Statistics.Distribution (cumulative, quantile)
 import Statistics.Distribution.Normal
-import Statistics.Distribution (cumulative, quantile)
 import Statistics.Resampling (Resample(..), jackknife)
 import Statistics.Sample (mean)
 import Statistics.Types (Estimator, Sample)
+import qualified Data.Vector.Unboxed as U
 
 -- | A point and interval estimate computed via an 'Estimator'.
 data Estimate = Estimate {

Statistics/Sample.hs

     -- $references
     ) where
 
-import qualified Data.Vector.Unboxed as U
 import Statistics.Function (minMax)
 import Statistics.Types (Sample,WeightedSample)
+import qualified Data.Vector.Unboxed as U
 
 
 range :: Sample -> Double

Statistics/Sample/Powers.hs

     -- $references
     ) where
 
-import qualified Data.Vector.Unboxed as U
-import qualified Data.Vector.Unboxed.Mutable as MU
 import Data.Vector.Generic (unsafeFreeze)
 import Data.Vector.Unboxed ((!))
 import Prelude hiding (sum)
 import Statistics.Math (choose)
 import Statistics.Types (Sample)
 import System.IO.Unsafe (unsafePerformIO)
+import qualified Data.Vector.Unboxed as U
+import qualified Data.Vector.Unboxed.Mutable as MU
 
 newtype Powers = Powers (U.Vector Double)
     deriving (Eq, Show)
     Statistics.KernelDensity
     Statistics.Math
     Statistics.Quantile
-    Statistics.RandomVariate
     Statistics.Resampling
     Statistics.Resampling.Bootstrap
     Statistics.Sample