Data.Histogram.Bin.BinF
- data BinF f = BinF !f !f !Int
- binF :: RealFrac f => f -> Int -> f -> BinF f
- binFn :: RealFrac f => f -> f -> f -> BinF f
- binFstep :: RealFrac f => f -> f -> Int -> BinF f
- scaleBinF :: RealFrac f => f -> f -> BinF f -> BinF f
- data BinD = BinD !Double !Double !Int
- binD :: Double -> Int -> Double -> BinD
- binDn :: Double -> Double -> Double -> BinD
- binDstep :: Double -> Double -> Int -> BinD
- scaleBinD :: Double -> Double -> BinD -> BinD
Generic and slow
Floaintg point bins with equal sizes.
Note that due to GHC bug #2271 this toIndex is really slow (20x slowdown with respect to BinD) and use of BinD is recommended
- Lower bound
- Size of bin
- Number of bins
Instances
| Typeable1 BinF | |
| RealFrac f => ConvertBin BinI (BinF f) | |
| RealFrac f => ConvertBin BinInt (BinF f) | |
| Eq f => Eq (BinF f) | |
| Data f => Data (BinF f) | |
| (Read f, RealFrac f) => Read (BinF f) | |
| Show f => Show (BinF f) | |
| RealFrac f => UniformBin (BinF f) | |
| RealFrac f => VariableBin (BinF f) | |
| RealFrac f => GrowBin (BinF f) | |
| RealFrac f => Bin1D (BinF f) | |
| RealFrac f => IntervalBin (BinF f) | |
| RealFrac f => Bin (BinF f) |
Arguments
| :: RealFrac f | |
| => f | Lower bound of range |
| -> Int | Number of bins |
| -> f | Upper bound of range |
| -> BinF f |
Create bins.
Arguments
| :: RealFrac f | |
| => f | Begin of range |
| -> f | Size of step |
| -> f | Approximation of end of range |
| -> BinF f |
Create bins. Note that actual upper bound can differ from specified.
Create bins
scaleBinF :: RealFrac f => f -> f -> BinF f -> BinF fSource
'scaleBinF a b' scales BinF using linear transform 'a+b*x'
Specialized for Double and fast
Floaintg point bins with equal sizes. If you work with Doubles this data type should be used instead of BinF.
- Lower bound
- Size of bin
- Number of bins
Create bins.
Arguments
| :: Double | Begin of range |
| -> Double | Size of step |
| -> Double | Approximation of end of range |
| -> BinD |
Create bins. Note that actual upper bound can differ from specified.
Create bins