Chart-1.9.5: A library for generating 2D Charts and Plots

Copyright | (c) Tim Docker 2010 2014
License | BSD-style (see chart/COPYRIGHT)
Safe Haskell | None
Language | Haskell98

Graphics.Rendering.Chart.Axis.Indexed

Description

Calculate and render indexed axes

Synopsis

- newtype PlotIndex = PlotIndex {
  - plotindex_i :: Int
  }
- autoIndexAxis' :: Integral i => Bool -> [String] -> AxisFn i
- autoIndexAxis :: Integral i => [String] -> AxisFn i
- addIndexes :: [a] -> [(PlotIndex, a)]

# Documentation

newtype PlotIndex #

Type for capturing values plotted by index number (ie position in a list) rather than a numerical value.

Constructors

PlotIndex |
Fields plotindex_i :: Int

#### Instances

Instances details

PlotValue PlotIndex # |
Instance details Defined in Graphics.Rendering.Chart.Axis.Indexed Methods toValue :: PlotIndex -> Double # fromValue :: Double -> PlotIndex # autoAxis :: AxisFn PlotIndex #
Enum PlotIndex # |
Instance details Defined in Graphics.Rendering.Chart.Axis.Indexed Methods succ :: PlotIndex -> PlotIndex # pred :: PlotIndex -> PlotIndex # toEnum :: Int -> PlotIndex # fromEnum :: PlotIndex -> Int # enumFrom :: PlotIndex -> [PlotIndex] # enumFromThen :: PlotIndex -> PlotIndex -> [PlotIndex] # enumFromTo :: PlotIndex -> PlotIndex -> [PlotIndex] # enumFromThenTo :: PlotIndex -> PlotIndex -> PlotIndex -> [PlotIndex] #
Num PlotIndex # |
Instance details Defined in Graphics.Rendering.Chart.Axis.Indexed Methods (+) :: PlotIndex -> PlotIndex -> PlotIndex # (-) :: PlotIndex -> PlotIndex -> PlotIndex # (*) :: PlotIndex -> PlotIndex -> PlotIndex # negate :: PlotIndex -> PlotIndex # abs :: PlotIndex -> PlotIndex # signum :: PlotIndex -> PlotIndex # fromInteger :: Integer -> PlotIndex #
Integral PlotIndex # |
Instance details Defined in Graphics.Rendering.Chart.Axis.Indexed Methods quot :: PlotIndex -> PlotIndex -> PlotIndex # rem :: PlotIndex -> PlotIndex -> PlotIndex # div :: PlotIndex -> PlotIndex -> PlotIndex # mod :: PlotIndex -> PlotIndex -> PlotIndex # quotRem :: PlotIndex -> PlotIndex -> (PlotIndex, PlotIndex) # divMod :: PlotIndex -> PlotIndex -> (PlotIndex, PlotIndex) # toInteger :: PlotIndex -> Integer #
Real PlotIndex # |
Instance details Defined in Graphics.Rendering.Chart.Axis.Indexed Methods toRational :: PlotIndex -> Rational #
Show PlotIndex # |
Instance details Defined in Graphics.Rendering.Chart.Axis.Indexed Methods showsPrec :: Int -> PlotIndex -> ShowS # show :: PlotIndex -> String # showList :: [PlotIndex] -> ShowS #
Eq PlotIndex # |
Instance details Defined in Graphics.Rendering.Chart.Axis.Indexed Methods (==) :: PlotIndex -> PlotIndex -> Bool # (/=) :: PlotIndex -> PlotIndex -> Bool #
Ord PlotIndex # |
Instance details Defined in Graphics.Rendering.Chart.Axis.Indexed Methods compare :: PlotIndex -> PlotIndex -> Ordering # (<) :: PlotIndex -> PlotIndex -> Bool # (<=) :: PlotIndex -> PlotIndex -> Bool # (>) :: PlotIndex -> PlotIndex -> Bool # (>=) :: PlotIndex -> PlotIndex -> Bool # max :: PlotIndex -> PlotIndex -> PlotIndex # min :: PlotIndex -> PlotIndex -> PlotIndex #

autoIndexAxis' :: Integral i => Bool -> [String] -> AxisFn i #

Create an axis for values indexed by position. The list of strings are the labels to be used.

autoIndexAxis :: Integral i => [String] -> AxisFn i #

addIndexes :: [a] -> [(PlotIndex, a)] #

Augment a list of values with index numbers for plotting.