-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Statistics -- -- Purely functional interface for statistics based on hmatrix and -- hmatrix-gsl-stats -- -- When hmatrix is installed with -fvector, the vector type is -- Data.Vector.Storable from the vector package and compatible with the -- statistics package -- <http:hackage.haskell.orgpackagestatistics -- -- Feature requests, suggestions, and bug fixes welcome. @package hstatistics @version 0.2.2.7 -- | Methods for tests using surrogate data module Numeric.Statistics.Surrogate -- | perform an analysis using surrogate data surrogate :: Int -> Int -> (Array Int (Vector Double) -> a) -> Array Int (Vector Double) -> Array Int a -- | create histograms from density functions module Numeric.Statistics.Histogram cumulativeToHistogram :: (Double -> Double) -> Vector Double -> Histogram gaussianHistogram :: Double -> Double -> Vector Double -> Histogram -- | Probability Distribution Function interface module Numeric.Statistics.PDF -- | a probability distribution function -- -- a PDF interface data PDFFunction a class PDF b a probability :: PDF b a => b -> Vector a -> Vector Double -- | create a PDF from an arbtrary function f :-> [0,1] pdfFromFunction :: (a -> Double) -> PDFFunction a instance PDF Histogram2D (Double, Double) instance PDF Histogram Double instance Storable b => PDF (PDFFunction b) b -- | Shannon entropy module Numeric.Statistics.Information -- | the entropy sum p_i lln{p_i} of a sequence entropy :: PDF a Double => a -> Vector Double -> Double -- | the mutual information sum_x sum_y p(x,y) ln{frac{p(x,y)}{p(x)p(y)}} mutual_information :: (PDF a Double, PDF b (Double, Double)) => b -> a -> a -> (Vector Double, Vector Double) -> Double -- | Useful statistical functions module Numeric.Statistics type Sample a = Vector a type Samples a = Array Int (Vector a) -- | the covariance matrix covarianceMatrix :: Samples Double -> Matrix Double -- | the mean of a list of vectors meanList :: (Container Vector a, Num (Vector a)) => [Sample a] -> Sample a -- | the mean of an array of vectors meanArray :: (Container Vector a, Num (Vector a)) => Samples a -> Sample a -- | the mean of a matrix with data series in rows meanMatrix :: (Container Vector a, Num (Vector a), Element a) => Matrix a -> Sample a -- | the variance of a list of vectors varianceList :: (Container Vector a, Floating (Vector a)) => [Sample a] -> Sample a -- | the variance of an array of vectors varianceArray :: (Container Vector a, Floating (Vector a)) => Samples a -> Sample a -- | the variance of a matrix with data series in rows varianceMatrix :: (Container Vector a, Floating (Vector a), Element a) => Matrix a -> Sample a -- | Principal Components Analysis module Numeric.Statistics.PCA -- | find the n principal components of multidimensional data pca :: Array Int (Vector Double) -> Double -> Matrix Double -- | perform a PCA transform of the original data (remove mean) | Final = -- M^T Data^T pcaTransform :: Array Int (Vector Double) -> Matrix Double -> Array Int (Vector Double) -- | perform a dimension-reducing PCA modification pcaReduce :: Array Int (Vector Double) -> Double -> Array Int (Vector Double) -- | Independent Components Analysis -- -- implements the FastICA algorithm found in: -- -- -- -- -- http://www.google.com/url?sa=t&source=web&cd=2&ved=0CBgQFjAB&url=http%3A%2F%2Fciteseerx.ist.psu.edu%2Fviewdoc%2Fdownload%3Fdoi%3D10.1.1.79.7003%26rep%3Drep1%26type%3Dpdf&ei=RQozTJb6L4_fcbCV6cMD&usg=AFQjCNGClLIB9MAvbrEj45SyUx9cYubLyA&sig2=hg5Wnfy3dLPkoIc1hqSfjg module Numeric.Statistics.ICA -- | sigmoid transfer function sigmoid :: Double -> Double -- | derivative of sigmoid transfer function sigmoid' :: Double -> Double -- | remove the mean from data demean :: Array Int (Vector Double) -> (Array Int (Vector Double), Vector Double) -- | whiten data whiten :: Array Int (Vector Double) -> Double -> (Array Int (Vector Double), Matrix Double) -- | perform an ICA transform ica :: Int -> (Double -> Double) -> (Double -> Double) -> NormType -> Double -> Int -> Array Int (Vector Double) -> (Array Int (Vector Double), Matrix Double) -- | ICA with default values: no dimension reduction, euclidean norms, 16 -- sample groups, sigmoid icaDefaults :: Int -> Array Int (Vector Double) -> (Array Int (Vector Double), Matrix Double)