-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | GSL Statistics interface
--   
--   Purely functional interface for statistics based on hmatrix and GSL
--   
--   Relieves the burden of alloc/free routines and is otherwise
--   essentially 1:1
--   
--   Documentation can be found at
--   <a>http://www.gnu.org/software/gsl/manual/</a>
--   
--   The vector type is Data.Vector.Storable from the <a>vector</a>
--   package.
@package hmatrix-gsl-stats
@version 0.4.1.7


-- | GSL common data types for distributions
--   
--   <a>http://www.gnu.org/software/gsl/manual/</a>
--   
--   FOr information on how to set environment variables to set RNG type
--   and seed see
--   <a>http://www.gnu.org/software/gsl/manual/html_node/Random-number-environment-variables.html#Random-number-environment-variables</a>
module Numeric.GSL.Distribution.Common
data DistFunc

-- | pdf
Density :: DistFunc

-- | lower cdf
Lower :: DistFunc

-- | upper cdf
Upper :: DistFunc

-- | lower inverse cdf
LowInv :: DistFunc

-- | upper inverse cdf
UppInv :: DistFunc
data RNG

-- | create a random number generator (RNG) object
newRNG :: IO RNG

-- | assign a new seed to an RNG
seedRNG :: RNG -> Int -> IO ()
instance GHC.Classes.Eq Numeric.GSL.Distribution.Common.DistFunc
instance GHC.Enum.Enum Numeric.GSL.Distribution.Common.DistFunc


-- | GSL discrete random distribution functions
--   
--   <a>http://www.gnu.org/software/gsl/manual/</a>
module Numeric.GSL.Distribution.Discrete
data OneParamDist

-- | mean
Poisson :: OneParamDist

-- | probability
Bernoulli :: OneParamDist

-- | probability
Geometric :: OneParamDist

-- | probability
Logarithmic :: OneParamDist
data TwoParamDist

-- | probability, successes
Binomial :: TwoParamDist

-- | probability, successes
NegBinomial :: TwoParamDist

-- | probability, n
Pascal :: TwoParamDist
data ThreeParamDist

-- | number type 1, number type 2, samples
HyperGeometric :: ThreeParamDist
data MultiParamDist

-- | trials, probabilities
Multinomial :: MultiParamDist
data DistFunc

-- | pdf
Density :: DistFunc

-- | lower cdf
Lower :: DistFunc

-- | upper cdf
Upper :: DistFunc

-- | lower inverse cdf
LowInv :: DistFunc

-- | upper inverse cdf
UppInv :: DistFunc

-- | draw a sample from a one parameter distribution
random_1p :: OneParamDist -> Int -> Double -> Word32

-- | draw samples from a one parameter distribution
random_1p_v :: OneParamDist -> Int -> Double -> Int -> Vector Word32

-- | probability of a variate take a value outside the argument
density_1p :: OneParamDist -> DistFunc -> Double -> Word32 -> Double

-- | draw a sample from a two parameter distribution
random_2p :: TwoParamDist -> Int -> Double -> Word32 -> Word32

-- | draw samples from a two parameter distribution
random_2p_v :: TwoParamDist -> Int -> Double -> Word32 -> Int -> Vector Word32

-- | probability of a variate take a value outside the argument
density_2p :: TwoParamDist -> DistFunc -> Double -> Word32 -> Word32 -> Double

-- | draw a sample from a three parameter distribution
random_3p :: ThreeParamDist -> Int -> Word32 -> Word32 -> Word32 -> Word32

-- | draw samples from a three parameter distribution
random_3p_v :: ThreeParamDist -> Int -> Word32 -> Word32 -> Word32 -> Int -> Vector Word32

-- | probability of a variate take a value outside the argument
density_3p :: ThreeParamDist -> DistFunc -> Word32 -> Word32 -> Word32 -> Word32 -> Double

-- | draw a sample from a multi-parameter distribution
random_mp :: MultiParamDist -> Int -> Word32 -> Vector Double -> Vector Word32

-- | probability of a variate take a value outside the argument
density_mp :: MultiParamDist -> DistFunc -> Vector Double -> Vector Word32 -> Double
instance GHC.Enum.Enum Numeric.GSL.Distribution.Discrete.MultiParamDist
instance GHC.Enum.Enum Numeric.GSL.Distribution.Discrete.ThreeParamDist
instance GHC.Enum.Enum Numeric.GSL.Distribution.Discrete.TwoParamDist
instance GHC.Enum.Enum Numeric.GSL.Distribution.Discrete.OneParamDist


-- | GSL continuous random distribution functions
--   
--   <a>http://www.gnu.org/software/gsl/manual/</a>
module Numeric.GSL.Distribution.Continuous
data ZeroParamDist
Landau :: ZeroParamDist
data OneParamDist

-- | standard deviation
Gaussian :: OneParamDist

-- | mean
Exponential :: OneParamDist

-- | width
Laplace :: OneParamDist

-- | scale
Cauchy :: OneParamDist

-- | standard deviation
Rayleigh :: OneParamDist

-- | degrees of freedom
ChiSq :: OneParamDist

-- | degrees of freedom
TDist :: OneParamDist

-- | scale
Logistic :: OneParamDist
data TwoParamDist

-- | limit, standard deviation
GaussianTail :: TwoParamDist

-- | scale, exponent
ExpPower :: TwoParamDist

-- | lower limit, standard deviation
RayleighTail :: TwoParamDist

-- | scale, exponent
Levy :: TwoParamDist

-- | par1, par2
Gamma :: TwoParamDist

-- | lower, upper
Uniform :: TwoParamDist

-- | offset, standard deviation
Lognormal :: TwoParamDist

-- | degrees of freedom, degrees of freedom
FDist :: TwoParamDist

-- | parameter a, parameter b
Beta :: TwoParamDist

-- | exponent, scale
Pareto :: TwoParamDist

-- | scale, exponent
Weibull :: TwoParamDist

-- | A, B
GumbellI :: TwoParamDist

-- | A, B
GumbellII :: TwoParamDist
data ThreeParamDist

-- | scale, exponent, skewness
LevySkew :: ThreeParamDist
data MultiParamDist

-- | size, alpha
Dirichlet :: MultiParamDist
data BivariateDist

-- | standard deviation, standard deviation, correlation coefficient
BiGaussian :: BivariateDist
data DistFunc

-- | pdf
Density :: DistFunc

-- | lower cdf
Lower :: DistFunc

-- | upper cdf
Upper :: DistFunc

-- | lower inverse cdf
LowInv :: DistFunc

-- | upper inverse cdf
UppInv :: DistFunc

-- | draw a sample from a zero parameter distribution
random_0p :: ZeroParamDist -> Int -> Double

-- | draw a sample from a zero parameter distribution
random_0p_s :: RNG -> ZeroParamDist -> IO Double

-- | draw samples from a zero parameter distribution
random_0p_v :: ZeroParamDist -> Int -> Int -> Vector Double

-- | probability of a variate take a value outside the argument
density_0p :: ZeroParamDist -> DistFunc -> Double -> Double

-- | draw a sample from a one parameter distribution
random_1p :: OneParamDist -> Int -> Double -> Double

-- | draw a sample from a one parameter distribution
random_1p_s :: RNG -> OneParamDist -> Double -> IO Double

-- | draw samples from a one parameter distribution
random_1p_v :: OneParamDist -> Int -> Double -> Int -> Vector Double

-- | probability of a variate take a value outside the argument
density_1p :: OneParamDist -> DistFunc -> Double -> Double -> Double

-- | draw a sample from a two parameter distribution
random_2p :: TwoParamDist -> Int -> Double -> Double -> Double

-- | draw a sample from a two parameter distribution
random_2p_s :: RNG -> TwoParamDist -> Double -> Double -> IO Double

-- | draw samples from a two parameter distribution
random_2p_v :: TwoParamDist -> Int -> Double -> Double -> Int -> Vector Double

-- | probability of a variate take a value outside the argument
density_2p :: TwoParamDist -> DistFunc -> Double -> Double -> Double -> Double

-- | draw a sample from a three parameter distribution
random_3p :: ThreeParamDist -> Int -> Double -> Double -> Double -> Double

-- | draw a sample from a three parameter distribution
random_3p_s :: RNG -> ThreeParamDist -> Double -> Double -> Double -> IO Double

-- | draw samples from a three parameter distribution
random_3p_v :: ThreeParamDist -> Int -> Double -> Double -> Double -> Int -> Vector Double

-- | probability of a variate take a value outside the argument
density_3p :: ThreeParamDist -> DistFunc -> Double -> Double -> Double -> Double -> Double

-- | draw a sample from a multi parameter distribution
random_mp :: MultiParamDist -> Int -> Vector Double -> Vector Double

-- | draw a sample from a multi parameter distribution
random_mp_s :: RNG -> MultiParamDist -> Vector Double -> IO (Vector Double)

-- | probability of a variate take a value outside the argument
density_mp :: MultiParamDist -> DistFunc -> Vector Double -> Vector Double -> Double

-- | draw a sample from a bivariate distribution
random_biv :: BivariateDist -> Int -> Double -> Double -> Double -> (Double, Double)

-- | draw a sample from a bivariate distribution
random_biv_s :: RNG -> BivariateDist -> Double -> Double -> Double -> IO (Double, Double)

-- | draw a sample from a bivariate distribution
random_biv_v :: BivariateDist -> Int -> Double -> Double -> Double -> Int -> (Vector Double, Vector Double)

-- | probability of a variate take a value outside the argument
density_biv :: BivariateDist -> DistFunc -> Double -> Double -> Double -> (Double, Double) -> Double

-- | returns a normalised random direction vector from a multivariate
--   gaussian distribution
spherical_vector :: Int -> Int -> Vector Double
instance GHC.Enum.Enum Numeric.GSL.Distribution.Continuous.BivariateDist
instance GHC.Enum.Enum Numeric.GSL.Distribution.Continuous.MultiParamDist
instance GHC.Enum.Enum Numeric.GSL.Distribution.Continuous.ThreeParamDist
instance GHC.Enum.Enum Numeric.GSL.Distribution.Continuous.TwoParamDist
instance GHC.Enum.Enum Numeric.GSL.Distribution.Continuous.OneParamDist
instance GHC.Enum.Enum Numeric.GSL.Distribution.Continuous.ZeroParamDist


-- | GSL linear regression functions
--   
--   <a>http://www.gnu.org/software/gsl/manual/</a>
module Numeric.GSL.Fitting.Linear

-- | fits the model Y = C X
linear :: Vector Double -> Vector Double -> (Double, Double, Double, Double, Double, Double)

-- | fits the model Y = C X, with x data weighted
linear_w :: Vector Double -> Vector Double -> Vector Double -> (Double, Double, Double, Double, Double, Double)

-- | computes the fitted function and standard deviation at the input point
linear_est :: Double -> Double -> Double -> Double -> Double -> Double -> (Double, Double)

-- | fit the model Y = C X, with design matrix X | X is a design matrix
--   X_{ij} = x_j(i) with i observations and p predictors | a polynomial
--   would be X_{ij} = x_i^j | a fourier series would be X_{ij} = sin
--   (omega_j x_i)
multifit :: Matrix Double -> Vector Double -> (Vector Double, Matrix Double, Double)

-- | fit the model Y = C X, with design matrix X, and x weighted
multifit_w :: Matrix Double -> Vector Double -> Vector Double -> (Vector Double, Matrix Double, Double)

-- | computes the fitted function and standard deviation at the input point
multifit_est :: Vector Double -> Vector Double -> Matrix Double -> (Double, Double)


-- | GSL histogram functions
--   
--   <a>http://www.gnu.org/software/gsl/manual/</a>
module Numeric.GSL.Histogram

-- | A histogram structure
data Histogram

-- | create a histogram with n bins from ranges
--   (x0-&gt;x1),(x1-&gt;x2)..(xn-&gt;xn+1)
emptyRanges :: Vector Double -> Histogram

-- | create a histogram with n bins and lower and upper limits
emptyLimits :: Int -> (Double, Double) -> Histogram

-- | create a histogram with n bins from ranges
--   (x0-&gt;x1),(x1-&gt;x2)..(xn-&gt;xn+1) and increment from a vector
fromRanges :: Vector Double -> Vector Double -> Histogram

-- | create a histogram with n bins and lower and upper limits and
--   increment from a vector
fromLimits :: Int -> (Double, Double) -> Vector Double -> Histogram

-- | adds 1.0 to the correct bin for each element of the list
addList :: Histogram -> [Double] -> Histogram

-- | adds 1.0 to the correct bin for each element of the vector
addVector :: Histogram -> Vector Double -> Histogram

-- | adds the appropriate weight for each element of the list
addListWeighted :: Histogram -> [(Double, Double)] -> Histogram

-- | adds the appropriate weight for each element of the list
addVectorWeighted :: Histogram -> Vector Double -> Vector Double -> Histogram

-- | extract the ranges and bin weights
toVectors :: Histogram -> (Vector Double, Vector Double)

-- | create a histogram from the ranges and bin weights
fromVectors :: Vector Double -> Vector Double -> Histogram

-- | returns the contents of the i-th bin
getBin :: Histogram -> Int -> Double

-- | returns the upper and lower limits of the i-th bin
getRange :: Histogram -> Int -> (Double, Double)

-- | the maximum upper range limit
getMax :: Histogram -> Double

-- | the minimum lower range limit
getMin :: Histogram -> Double

-- | the number of bins
getBins :: Histogram -> Int

-- | find the bin corresponding to the value
find :: Histogram -> Double -> Maybe Int

-- | find the number of occurences for each element of the input vector
count :: Histogram -> Vector Double -> Vector Double

-- | find the probability of occurring for each element of the input vector
prob :: Histogram -> Vector Double -> Vector Double

-- | find the number of occurences for the input
countInstance :: Histogram -> Double -> Double

-- | find the probability of the input
probability :: Histogram -> Double -> Double

-- | the maximum value contained in the bins
maxVal :: Histogram -> Double

-- | the index of the bin containing the maximum value
maxBin :: Histogram -> Int

-- | the minimum value contained in the bins
minVal :: Histogram -> Double

-- | the index of the bin containing the minimum value
minBin :: Histogram -> Int

-- | the mean of the values, accuracy limited by bin width
mean :: Histogram -> Double

-- | the standard deviation of the values, accuracy limited by bin width
stddev :: Histogram -> Double

-- | the sum of the values, accuracy limited by bin width
sum :: Histogram -> Double

-- | returns True of all the individual bin ranges of the two histograms
--   are identical
equalBins :: Histogram -> Histogram -> Bool

-- | adds the contents of the bins of the second histogram to the first
add :: Histogram -> Histogram -> Histogram

-- | subtracts the contents of the bins of the second histogram from the
--   first
subtract :: Histogram -> Histogram -> Histogram

-- | multiplies the contents of the bins of the second histogram by the
--   first
multiply :: Histogram -> Histogram -> Histogram

-- | divides the contents of the bins of the first histogram by the second
divide :: Histogram -> Histogram -> Histogram

-- | adds a constant to the contents of the bins
shift :: Histogram -> Double -> Histogram

-- | multiplies the contents of the bins by a constant
scale :: Histogram -> Double -> Histogram

-- | write a histogram in the native binary format (may not be portable)
fwriteHistogram :: FilePath -> Histogram -> IO ()

-- | read a histogram in the native binary format, number of bins must be
--   known
freadHistogram :: FilePath -> Int -> IO Histogram

-- | saves the histogram with the given formats (%f,%e,%g) for ranges and
--   bins each line comprises: range[i] range[i+1] bin[i]
fprintfHistogram :: FilePath -> String -> String -> Histogram -> IO ()

-- | reads formatted data as written by fprintf, the number of bins must be
--   known in advance
fscanfHistogram :: FilePath -> Int -> IO Histogram

-- | A histogram-derived cumulative distribution function (CDF)
data HistogramPDF

-- | create a histogram PDF from a histogram
fromHistogram :: Histogram -> HistogramPDF

-- | given a random number from the uniform distribution [0,1], draw a
--   random sample from the PDF
sample :: HistogramPDF -> Double -> Double
instance GHC.Classes.Eq Numeric.GSL.Histogram.Histogram
instance Data.Binary.Class.Binary Numeric.GSL.Histogram.Histogram


-- | GSL 2D histogram functions
--   
--   <a>http://www.gnu.org/software/gsl/manual/</a>
module Numeric.GSL.Histogram2D

-- | A histogram structure
data Histogram2D

-- | create a histogram with n bins from ranges
--   (x0-&gt;x1),(x1-&gt;x2)..(xn-&gt;xn+1)
emptyRanges :: Vector Double -> Vector Double -> Histogram2D

-- | create a histogram with n bins and lower and upper limits
emptyLimits :: Int -> Int -> (Double, Double) -> (Double, Double) -> Histogram2D

-- | create a histogram with n bins from ranges
--   (x0-&gt;x1),(x1-&gt;x2)..(xn-&gt;xn+1) and increment from a vector
fromRanges :: Vector Double -> Vector Double -> [(Double, Double)] -> Histogram2D

-- | create a histogram with n bins and lower and upper limits and
--   increment from a vector
fromLimits :: Int -> Int -> (Double, Double) -> (Double, Double) -> [(Double, Double)] -> Histogram2D

-- | add 1.0 to the correct bin for each element of the list, fails
--   silently if the value is outside the range
addList :: Histogram2D -> [(Double, Double)] -> Histogram2D

-- | add 1.0 to the correct bin for each element of the vector pair, fails
--   silently if the value is outside the range
addVector :: Histogram2D -> Vector Double -> Vector Double -> Histogram2D
addListWeighted :: Histogram2D -> [(Double, Double, Double)] -> Histogram2D
addVectorWeighted :: Histogram2D -> Vector Double -> Vector Double -> Vector Double -> Histogram2D

-- | extract the ranges and bins
toMatrix :: Histogram2D -> (Vector Double, Vector Double, Matrix Double)

-- | create from ranges and bins
fromMatrix :: Vector Double -> Vector Double -> Matrix Double -> Histogram2D

-- | returns the contents of the i-th bin
getBin :: Histogram2D -> (Int, Int) -> Double

-- | returns the upper and lower limits in the first dimension of the i-th
--   bin
getXRange :: Histogram2D -> Int -> (Double, Double)

-- | returns the upper and lower limits in the second dimension of the i-th
--   bin
getYRange :: Histogram2D -> Int -> (Double, Double)

-- | the maximum upper range limit in the first dimension
getXMax :: Histogram2D -> Double

-- | the maximum upper range limit in the first dimension
getYMax :: Histogram2D -> Double

-- | the minimum lower range limit in the first dimension
getXMin :: Histogram2D -> Double

-- | the minimum lower range limit in the first dimension
getYMin :: Histogram2D -> Double

-- | the number of binsin the first dimension
getXBins :: Histogram2D -> Int

-- | the number of binsin the first dimension
getYBins :: Histogram2D -> Int

-- | reset all the bins to zero
reset :: Histogram2D -> IO ()

-- | find the bin corresponding to the value
find :: Histogram2D -> (Double, Double) -> Maybe (Int, Int)

-- | find the number of occurences for each element of the input vector
count :: Histogram2D -> (Vector Double, Vector Double) -> Vector Double

-- | find the joint probability of occuring for each element of the input
--   vector pair
prob :: Histogram2D -> (Vector Double, Vector Double) -> Vector Double

-- | find the joint probability of occuring for each element of the input
--   vector pair
probPaired :: Histogram2D -> (Vector (Double, Double)) -> Vector Double

-- | find the number of occurences for each element of the input vector
countPaired :: Histogram2D -> Vector (Double, Double) -> Vector Double

-- | find the number of occurences for the input
countInstance :: Histogram2D -> (Double, Double) -> Double

-- | find the probability of the input
probability :: Histogram2D -> (Double, Double) -> Double

-- | the maximum value contained in the bins
maxVal :: Histogram2D -> Double

-- | the index of the bin containing the maximum value
maxBin :: Histogram2D -> (Int, Int)

-- | the minimum value contained in the bins
minVal :: Histogram2D -> Double

-- | the index of the bin containing the minimum value
minBin :: Histogram2D -> (Int, Int)

-- | the mean of the values in the first dimension, accuracy limited by bin
--   width
xmean :: Histogram2D -> Double

-- | the mean of the values in the second dimension, accuracy limited by
--   bin width
ymean :: Histogram2D -> Double

-- | the standard deviation of the values in thee first dimension, accuracy
--   limited by bin width
xstddev :: Histogram2D -> Double

-- | the standard deviation of the values in thee first dimension, accuracy
--   limited by bin width
ystddev :: Histogram2D -> Double

-- | the covariance of the first and second dimensions
covariance :: Histogram2D -> Double

-- | the sum of the values, accuracy limited by bin width
sum :: Histogram2D -> Double

-- | returns True of all the individual bin ranges of the two histograms
--   are identical
equalBins :: Histogram2D -> Histogram2D -> Bool

-- | adds the contents of the bins of the second histogram to the first
add :: Histogram2D -> Histogram2D -> Histogram2D

-- | subtracts the contents of the bins of the second histogram from the
--   first
subtract :: Histogram2D -> Histogram2D -> Histogram2D

-- | multiplies the contents of the bins of the second histogram by the
--   first
multiply :: Histogram2D -> Histogram2D -> Histogram2D

-- | divides the contents of the bins of the first histogram by the second
divide :: Histogram2D -> Histogram2D -> Histogram2D

-- | adds a constant to the contents of the bins
shift :: Histogram2D -> Double -> Histogram2D

-- | multiplies the contents of the bins by a constant
scale :: Histogram2D -> Double -> Histogram2D

-- | write a histogram in the native binary format (may not be portable)
fwriteHistogram2D :: FilePath -> Histogram2D -> IO ()

-- | read a histogram in the native binary format, number of bins must be
--   known
freadHistogram2D :: FilePath -> Int -> Int -> IO Histogram2D

-- | saves the histogram with the given formats (%f,%e,%g) for ranges and
--   bins each line comprises: xrange[i] xrange[i+1] xrange[j] xrange[j+1]
--   bin(i,j)
fprintfHistogram2D :: FilePath -> String -> String -> Histogram2D -> IO ()

-- | reads formatted data as written by fprintf, the number of bins must be
--   known in advance
fscanfHistogram2D :: FilePath -> Int -> Int -> IO Histogram2D

-- | A histogram-derived cumulative distribution function (CDF)
data Histogram2DPDF

-- | create a histogram PDF from a histogram
fromHistogram2D :: Histogram2D -> Histogram2DPDF

-- | given a randomm from the uniform distribution [0,1], draw a random
--   sample from the PDF
sample :: Histogram2DPDF -> Double -> Double
instance GHC.Classes.Eq Numeric.GSL.Histogram2D.Histogram2D
instance Data.Binary.Class.Binary Numeric.GSL.Histogram2D.Histogram2D
instance Foreign.Storable.Storable a => Foreign.Storable.Storable (a, a)


-- | GSL permutation functions
--   
--   <a>http://www.gnu.org/software/gsl/manual/</a>
module Numeric.GSL.Permutation

-- | A permutation structure
data Permutation

-- | A canonical permutation structure
data CanPerm

-- | generate a random permutation
random_permute :: Int -> Int -> Permutation

-- | returns the value of the i-th element of the permutation
get :: Permutation -> Int -> Int

-- | swaps the i-th and j-th elements
swap :: Permutation -> Int -> Int -> Permutation

-- | swaps pairs of elements
swapList :: Permutation -> [(Int, Int)] -> Permutation

-- | get the length of the permutation
size :: Permutation -> Int

-- | checks that the permutation is valid
valid :: Permutation -> Bool

-- | reverse the elements of the permutation
reverse :: Permutation -> Permutation

-- | computes the inverse of the permutation
inverse :: Permutation -> Permutation

-- | advances the permutation to the next in lexicographic order, if there
--   is one
next :: Permutation -> IO Bool

-- | steps the permutation back to the previous in lexicographic order, if
--   there is one
prev :: Permutation -> IO Bool

-- | apply the permutation to a vector
permute :: Permutation -> Vector Double -> Vector Double

-- | apply the inverse permutation to a vector
inverse_permute :: Permutation -> Vector Double -> Vector Double

-- | multiply two permutations, P = PA * PB
mul :: Permutation -> Permutation -> Permutation

-- | write a permutation in the native binary format (may not be portable)
fwritePermutation :: FilePath -> Permutation -> IO ()

-- | read a permutation in the native binary format, length must be known
freadPermutation :: FilePath -> Int -> IO Permutation

-- | saves the permutation with the given format
fprintfPermutation :: FilePath -> String -> Permutation -> IO ()

-- | reads formatted data as written by fprintf, the number of bins must be
--   known in advance
fscanfPermutation :: FilePath -> Int -> IO Permutation

-- | compute the canonical form
canonical :: Permutation -> CanPerm

-- | convert from canonical to linear
linear :: CanPerm -> Permutation

-- | a count of the inversions
inversions :: Permutation -> Int

-- | a count of the cycles of a permutation in linear form
cyclesLinear :: Permutation -> Int

-- | a count of the cycles of a permutation in canonical form
cyclesCanonical :: CanPerm -> Int


-- | GSL sorting functions
--   
--   <a>http://www.gnu.org/software/gsl/manual/</a>
module Numeric.GSL.Sort

-- | sort the elements of a vector into ascending order
sort :: Vector Double -> Vector Double


-- | GSL statistics functions
--   
--   <a>http://www.gnu.org/software/gsl/manual/</a>
module Numeric.GSL.Statistics

-- | the mean of the elements of a vector
mean :: Vector Double -> Double

-- | the sample variance
variance :: Vector Double -> Double

-- | the sample variance given the precomputed mean
variance_m :: Double -> Vector Double -> Double

-- | the population variance given the a priori mean
variance_pm :: Double -> Vector Double -> Double

-- | the sample standard deviation
stddev :: Vector Double -> Double

-- | the sample standard deviation given the precomputed mean
stddev_m :: Double -> Vector Double -> Double

-- | the population standard deviation given the a priori mean
stddev_pm :: Double -> Vector Double -> Double

-- | the total sum of squares about the mean
tot_sumsq :: Vector Double -> Double

-- | the total sum of squares about the precomputed mean
tot_sumsq_m :: Double -> Vector Double -> Double

-- | the absolute deviation from the mean
absdev :: Vector Double -> Double

-- | the absolute deviation from the precomputed mean
absdev_m :: Double -> Vector Double -> Double

-- | the skewness of the data (asymmetry of tails)
skew :: Vector Double -> Double

-- | the skewness of the data (asymmetry of tails) with precomputed mean
--   and sd
skew_m_sd :: Double -> Double -> Vector Double -> Double

-- | the kurtosis of the data (sharpness of peak relative to width)
kurtosis :: Vector Double -> Double

-- | the kurtosis of the data (sharpness of peak relative to width) with
--   precomputed mean and sd
kurtosis_m_sd :: Double -> Double -> Vector Double -> Double

-- | the weighted mean of the elements of a vector
mean_w :: Vector Double -> Vector Double -> Double

-- | the weighted sample variance
variance_w :: Vector Double -> Vector Double -> Double

-- | the weighted sample variance given the precomputed mean
variance_w_m :: Double -> Vector Double -> Vector Double -> Double

-- | the weighted population variance given the a priori mean
variance_w_pm :: Double -> Vector Double -> Vector Double -> Double

-- | the weighted sample standard deviation
stddev_w :: Vector Double -> Vector Double -> Double

-- | the weighted sample standard deviation given the precomputed mean
stddev_w_m :: Double -> Vector Double -> Vector Double -> Double

-- | the weighted population standard deviation given the a priori mean
stddev_w_pm :: Double -> Vector Double -> Vector Double -> Double

-- | the weighted total sum of squares about the mean
tot_sumsq_w :: Vector Double -> Vector Double -> Double

-- | the weighted total sum of squares about the precomputed mean
tot_sumsq_w_m :: Double -> Vector Double -> Vector Double -> Double

-- | the weighted absolute deviation from the mean
absdev_w :: Vector Double -> Vector Double -> Double

-- | the weighted absolute deviation from the precomputed mean
absdev_w_m :: Double -> Vector Double -> Vector Double -> Double

-- | the weighted skewness of the data (asymmetry of tails)
skew_w :: Vector Double -> Vector Double -> Double

-- | the weighted skewness of the data (asymmetry of tails) with
--   precomputed mean and sd
skew_w_m_sd :: Double -> Double -> Vector Double -> Vector Double -> Double

-- | the weighted kurtosis of the data (sharpness of peak relative to
--   width)
kurtosis_w :: Vector Double -> Vector Double -> Double

-- | the weighted kurtosis of the data (sharpness of peak relative to
--   width) with precomputed mean and sd
kurtosis_w_m_sd :: Double -> Double -> Vector Double -> Vector Double -> Double

-- | the lag-1 autocorrelation of the data
lag1auto :: Vector Double -> Double

-- | the covariance of two datasets of the same length
covariance :: Vector Double -> Vector Double -> Double

-- | the covariance of two datasets of the same length
covariance_m :: Double -> Double -> Vector Double -> Vector Double -> Double

-- | the Pearson correlation of two datasets of the same length
correlation :: Vector Double -> Vector Double -> Double

-- | the median value of the dataset, which must be sorted
median :: Vector Double -> Double

-- | the quantile value of the dataset, which must be sorted
quantile :: Double -> Vector Double -> Double
