Safe Haskell | None |
---|---|
Language | Haskell98 |
Collection of functions pertaining to finding the diversity of samples.
- hamming :: String -> String -> Int
- richness :: (Ord a, Ord b) => Map (a, b) c -> Int
- diversity :: Ord a => Double -> [a] -> Double
- diversityOfMap :: Ord a => Double -> Map a Int -> Double
- diversityOfMapWithContribution :: Ord a => Double -> Map a Int -> (Double, Map a Double)
- chao1 :: Ord a => Map a Int -> Double
- chao2 :: (Ord a, Ord b) => Map (a, b) Int -> Double
- chao1Var :: Ord a => Map a Int -> Double
- chao2Var :: (Ord a, Ord b) => Map (a, b) Int -> Double
- rarefactionCurve :: Bool -> Int -> Integer -> Integer -> Integer -> Map (Sample, Fragment) Int -> IO [(Int, Maybe (Double, Double))]
- rarefactionSampleCurve :: Bool -> Int -> Int -> Int -> Map (Sample, Fragment) Int -> IO [(Int, Maybe (Double, Double))]
- rarefactionViable :: [Double] -> Double
- individualG :: Double -> Map (Sample, Fragment) Int -> Double
- sampleG :: Double -> Map (Sample, Fragment) Int -> Double
- minRarefaction :: Bool -> Bool -> Int -> Map (Sample, Fragment) Int -> Double -> Int -> IO Int
Documentation
diversityOfMap :: Ord a => Double -> Map a Int -> Double Source #
Returns the diversity of a map of the species and how many times it appears
diversityOfMapWithContribution :: Ord a => Double -> Map a Int -> (Double, Map a Double) Source #
Returns the diversity of a map of the species and how many times it appears, along with the contribution of each species.
chao1 :: Ord a => Map a Int -> Double Source #
Returns the chao1 estimator of a map of the species and how many times it appears
chao2 :: (Ord a, Ord b) => Map (a, b) Int -> Double Source #
Returns the chao2 estimator of a map of the sample labeled species (sample, species) and how many times it appears. This will calculate the overlap for you, so if you don't have the number of times it appears it does not matter, you can set it to 1 and get the same result as it's all about overlapping samples.
chao1Var :: Ord a => Map a Int -> Double Source #
Returns the chao1 estimator variance of a map of the species and how many times each one appears.
chao2Var :: (Ord a, Ord b) => Map (a, b) Int -> Double Source #
Returns the chao2 estimator variance of a map of the sample labeled species (sample, species) and how many times it appears.
rarefactionCurve :: Bool -> Int -> Integer -> Integer -> Integer -> Map (Sample, Fragment) Int -> IO [(Int, Maybe (Double, Double))] Source #
Returns the rarefaction curve for each position in a list
rarefactionSampleCurve :: Bool -> Int -> Int -> Int -> Map (Sample, Fragment) Int -> IO [(Int, Maybe (Double, Double))] Source #
Returns the rarefaction curve for each position in a list
rarefactionViable :: [Double] -> Double Source #
Calculates the percent of the curve that is above 95% of height of the curve
individualG :: Double -> Map (Sample, Fragment) Int -> Double Source #
Returns the number of individuals needed to get the proportion g of the estimated total richness of the assemblage. Sobs / Sest < g < 1