plot-0.2.3.12: A plotting library, exportable as eps/pdf/svg/png or renderable with gtk
Copyright(c) A. V. H. McPhail 2010
LicenseBSD3
Maintainerhaskell.vivian.mcphail <at> gmail <dot> com
Stabilityprovisional
Portabilityportable
Safe HaskellNone
LanguageHaskell2010

Graphics.Rendering.Plot.Figure

Description

Creation and manipulation of Figures

The same problem of leaked instances as at http://hackage.haskell.org/packages/archive/graphviz/2999.10.0.1/doc/html/Data-GraphViz-Commands.html#t%3AGraphvizCanvas occurs here.

with, set, clear, new, and add are the operations that can be performed on various elements of a figure.

glib/data-accessor abstractions (verbs/modifiers) are planned for future implementations

Synopsis

Documentation

Top level operation

data Figure a Source #

Instances

Instances details
Applicative Figure Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

pure :: a -> Figure a #

(<*>) :: Figure (a -> b) -> Figure a -> Figure b #

liftA2 :: (a -> b -> c) -> Figure a -> Figure b -> Figure c #

(*>) :: Figure a -> Figure b -> Figure b #

(<*) :: Figure a -> Figure b -> Figure a #

Functor Figure Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

fmap :: (a -> b) -> Figure a -> Figure b #

(<$) :: a -> Figure b -> Figure a #

Monad Figure Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(>>=) :: Figure a -> (a -> Figure b) -> Figure b #

(>>) :: Figure a -> Figure b -> Figure b #

return :: a -> Figure a #

Simple Figure Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Simple

Methods

simple :: Plot () -> Figure ()

MonadState FigureState Figure Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

data FigureState Source #

Instances

Instances details
MonadState FigureState Figure Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Default options

withTextDefaults :: Text () -> Figure () Source #

perform some actions on the text defaults, must be run before other text element modifications

withLineDefaults :: Line () -> Figure () Source #

perform some actions on the line defaults, must be run before other line element modifications

withPointDefaults :: Point () -> Figure () Source #

perform some actions on the point defaults, must be run before other point modifications

withBarDefaults :: Bar () -> Figure () Source #

perform some actions on the bar defaults, must be run before other point modifications

Figures

newFigure :: Figure () Source #

create a new blank Figure

Formatting

setBackgroundColour :: Color -> Figure () Source #

set the background colour of the figure

setFigurePadding :: Double -> Double -> Double -> Double -> Figure () Source #

set the padding of the figure

withTitle :: Text () -> Figure () Source #

operate on the title

withSubTitle :: Text () -> Figure () Source #

operate on the sub-title

setPlots Source #

Arguments

:: Int

rows

-> Int

columns

-> Figure () 

set the shape of the plots, losing all current plots

withPlot :: (Int, Int) -> Plot () -> Figure () Source #

perform some actions on the specified subplot

withPlots :: Plot () -> Figure () Source #

perform some actions all subplots

Sub-plots

data Plot a Source #

Instances

Instances details
Applicative Plot Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

pure :: a -> Plot a #

(<*>) :: Plot (a -> b) -> Plot a -> Plot b #

liftA2 :: (a -> b -> c) -> Plot a -> Plot b -> Plot c #

(*>) :: Plot a -> Plot b -> Plot b #

(<*) :: Plot a -> Plot b -> Plot a #

Functor Plot Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

fmap :: (a -> b) -> Plot a -> Plot b #

(<$) :: a -> Plot b -> Plot a #

Monad Plot Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(>>=) :: Plot a -> (a -> Plot b) -> Plot b #

(>>) :: Plot a -> Plot b -> Plot b #

return :: a -> Plot a #

Simple Plot Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Simple

Methods

simple :: Plot () -> Plot ()

Colour

setPlotBackgroundColour :: Color -> Plot () Source #

set the plot background colour

Plot elements

setBorder :: Border -> Plot () Source #

whether to draw a boundary around the plot area

setPlotPadding :: Double -> Double -> Double -> Double -> Plot () Source #

set the padding of the subplot

withHeading :: Text () -> Plot () Source #

set the heading of the subplot

Series data

class Abscissa a Source #

Minimal complete definition

toAbscissa

Instances

Instances details
Abscissa Series Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toAbscissa :: Series -> Abscissae

class Ordinate a Source #

Minimal complete definition

toOrdinate

Instances

Instances details
Ordinate Function Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: Function -> Ordinates

Ordinate Series Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: Series -> Ordinates

Ordinate VectorFunction Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: VectorFunction -> Ordinates

Ordinate (Function, AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Function, AxisSide) -> Ordinates

Ordinate (Function, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Function, SeriesLabel) -> Ordinates

Ordinate (MinMaxSeries, (ErrorSeries, ErrorSeries)) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (MinMaxSeries, (ErrorSeries, ErrorSeries)) -> Ordinates

Ordinate (Series, AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, AxisSide) -> Ordinates

Ordinate (Series, ErrorSeries) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, ErrorSeries) -> Ordinates

Ordinate (Series, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, SeriesLabel) -> Ordinates

Ordinate (Series, (ErrorSeries, ErrorSeries)) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, (ErrorSeries, ErrorSeries)) -> Ordinates

Ordinate (VectorFunction, AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (VectorFunction, AxisSide) -> Ordinates

Ordinate (VectorFunction, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (VectorFunction, SeriesLabel) -> Ordinates

Ordinate (Function, AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Function, AxisSide, SeriesLabel) -> Ordinates

Ordinate (MinMaxSeries, (ErrorSeries, ErrorSeries), AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Ordinate (Series, AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, AxisSide, SeriesLabel) -> Ordinates

Ordinate (Series, ErrorSeries, AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, ErrorSeries, AxisSide) -> Ordinates

Ordinate (Series, ErrorSeries, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, ErrorSeries, SeriesLabel) -> Ordinates

Ordinate (Series, (ErrorSeries, ErrorSeries), AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, (ErrorSeries, ErrorSeries), AxisSide) -> Ordinates

Ordinate (Series, (ErrorSeries, ErrorSeries), SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, (ErrorSeries, ErrorSeries), SeriesLabel) -> Ordinates

Ordinate (VectorFunction, AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (VectorFunction, AxisSide, SeriesLabel) -> Ordinates

Ordinate (MinMaxSeries, (ErrorSeries, ErrorSeries), AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Ordinate (Series, ErrorSeries, AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, ErrorSeries, AxisSide, SeriesLabel) -> Ordinates

Ordinate (Series, (ErrorSeries, ErrorSeries), AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

class Dataset a Source #

Minimal complete definition

toDataSeries

Instances

Instances details
Dataset Surface Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toDataSeries :: Surface -> Data DataSeries

Dataset [FormattedSeries] Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toDataSeries :: [FormattedSeries] -> Data DataSeries

Abscissa a => Dataset [(a, FormattedSeries)] Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toDataSeries :: [(a, FormattedSeries)] -> Data DataSeries

(Abscissa a, Ordinate b) => Dataset [(SeriesType, a, b)] Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toDataSeries :: [(SeriesType, a, b)] -> Data DataSeries

Ordinate a => Dataset (SeriesType, [a]) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toDataSeries :: (SeriesType, [a]) -> Data DataSeries

Abscissa a => Dataset (a, [FormattedSeries]) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toDataSeries :: (a, [FormattedSeries]) -> Data DataSeries

(Abscissa a, Ordinate b) => Dataset (SeriesType, a, [b]) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toDataSeries :: (SeriesType, a, [b]) -> Data DataSeries

type FormattedSeries = Data DecoratedSeries Source #

data SeriesType Source #

Instances

Instances details
(Abscissa a, Ordinate b) => Dataset [(SeriesType, a, b)] Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toDataSeries :: [(SeriesType, a, b)] -> Data DataSeries

Ordinate a => Dataset (SeriesType, [a]) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toDataSeries :: (SeriesType, [a]) -> Data DataSeries

(Abscissa a, Ordinate b) => Dataset (SeriesType, a, [b]) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toDataSeries :: (SeriesType, a, [b]) -> Data DataSeries

bar :: (Ordinate a, BarFormat b) => a -> b -> FormattedSeries Source #

setDataset :: Dataset a => a -> Plot () Source #

set the data series of the subplot

The data series are either FormattedSeries or plain data series. A plain data series must carry a SeriesType.

A dataset may or may not have an abscissa series, and if so, it is paired with either a list of ordinate series or a single ordinate series.

The abscissa series (if present) is of type 'Vector Double'.

An ordinate series be a function (Double -> Double) or a series of points, a 'Vector Double' with optional error series, y axis preference, and labels.

To specify decoration options for an ordinate series, use the appropriate function, such as linespoints, with the ordinate series and decoration formatting (LineFormat, PointFormat, and BarFormat) as arguments.

setDataset (ts,[linespoints (xs,(le,ue),Upper,"data") (([Dash,Dash],3,blue),(Diamond,green))])

has abscissa ts paired with a list of ordinate series, the single element of which is a FormattedSeries, linespoints where the ordinate is xs with error series le and ue, to be graphed against the upper y-range with label "data". The line element is formatted to be dashed, of width 3, and blue and the point element is to be a green diamond.

Annotations

type Head = Bool Source #

type Fill = Bool Source #

data Annote a Source #

Instances

Instances details
Applicative Annote Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

pure :: a -> Annote a #

(<*>) :: Annote (a -> b) -> Annote a -> Annote b #

liftA2 :: (a -> b -> c) -> Annote a -> Annote b -> Annote c #

(*>) :: Annote a -> Annote b -> Annote b #

(<*) :: Annote a -> Annote b -> Annote a #

Functor Annote Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

fmap :: (a -> b) -> Annote a -> Annote b #

(<$) :: a -> Annote b -> Annote a #

Monad Annote Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(>>=) :: Annote a -> (a -> Annote b) -> Annote b #

(>>) :: Annote a -> Annote b -> Annote b #

return :: a -> Annote a #

arrow :: Head -> Location -> Location -> Line () -> Annote () Source #

add an arrow

oval :: Fill -> Location -> Location -> Bar () -> Annote () Source #

add an oval

rect :: Fill -> Location -> Location -> Bar () -> Annote () Source #

add a rectangle

glyph :: Location -> Point () -> Annote () Source #

add a rectangle

text :: Location -> Text () -> Annote () Source #

add text

cairo :: (Double -> Double -> Double -> Double -> Render ()) -> Annote () Source #

add a cairo render that takes the bounding box (in user coordinates) as an argument

Plot type

setSeriesType :: Int -> SeriesType -> Plot () Source #

set the plot type of a given data series

setAllSeriesTypes :: SeriesType -> Plot () Source #

change the plot type of all data series

Formatting

class PlotFormats (m :: Type -> Type) Source #

Minimal complete definition

modifyFormat

Instances

Instances details
PlotFormats Bar Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

modifyFormat :: Bar () -> DecoratedSeries -> Data DecoratedSeries

PlotFormats Line Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

modifyFormat :: Line () -> DecoratedSeries -> Data DecoratedSeries

PlotFormats Point Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

modifyFormat :: Point () -> DecoratedSeries -> Data DecoratedSeries

withSeriesFormat :: PlotFormats m => Int -> m () -> Plot () Source #

format the plot elements of a given series

withAllSeriesFormats :: PlotFormats m => (Int -> m ()) -> Plot () Source #

format the plot elements of all series

the operation to modify the formats is passed the series index. This allows, for example, colours to be selected from a list that gets indexed by the argument

setColour = withAllSeriesFormats (\i -> do
                                        setLineColour $ [black,blue,red,green,yellow] !! i
                                        setLineWidth 1.0)

Range

data Scale Source #

Constructors

Linear 
Log 

Instances

Instances details
Eq Scale Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(==) :: Scale -> Scale -> Bool #

(/=) :: Scale -> Scale -> Bool #

setRange :: AxisType -> AxisSide -> Scale -> Double -> Double -> Plot () Source #

set the axis range

setRangeFromData :: AxisType -> AxisSide -> Scale -> Plot () Source #

set the axis ranges to values based on dataset

Axes

data Axis a Source #

Instances

Instances details
Applicative Axis Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

pure :: a -> Axis a #

(<*>) :: Axis (a -> b) -> Axis a -> Axis b #

liftA2 :: (a -> b -> c) -> Axis a -> Axis b -> Axis c #

(*>) :: Axis a -> Axis b -> Axis b #

(<*) :: Axis a -> Axis b -> Axis a #

Functor Axis Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

fmap :: (a -> b) -> Axis a -> Axis b #

(<$) :: a -> Axis b -> Axis a #

Monad Axis Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(>>=) :: Axis a -> (a -> Axis b) -> Axis b #

(>>) :: Axis a -> Axis b -> Axis b #

return :: a -> Axis a #

data AxisType Source #

Constructors

XAxis 
YAxis 

Instances

Instances details
Eq AxisType Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

data AxisSide Source #

Constructors

Lower 
Upper 

Instances

Instances details
Eq AxisSide Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Ordinate (Function, AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Function, AxisSide) -> Ordinates

Ordinate (Series, AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, AxisSide) -> Ordinates

Ordinate (VectorFunction, AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (VectorFunction, AxisSide) -> Ordinates

Ordinate (Function, AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Function, AxisSide, SeriesLabel) -> Ordinates

Ordinate (MinMaxSeries, (ErrorSeries, ErrorSeries), AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Ordinate (Series, AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, AxisSide, SeriesLabel) -> Ordinates

Ordinate (Series, ErrorSeries, AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, ErrorSeries, AxisSide) -> Ordinates

Ordinate (Series, (ErrorSeries, ErrorSeries), AxisSide) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, (ErrorSeries, ErrorSeries), AxisSide) -> Ordinates

Ordinate (VectorFunction, AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (VectorFunction, AxisSide, SeriesLabel) -> Ordinates

Ordinate (MinMaxSeries, (ErrorSeries, ErrorSeries), AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Ordinate (Series, ErrorSeries, AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

toOrdinate :: (Series, ErrorSeries, AxisSide, SeriesLabel) -> Ordinates

Ordinate (Series, (ErrorSeries, ErrorSeries), AxisSide, SeriesLabel) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

data AxisPosn Source #

Constructors

Side AxisSide 
Value Double 

Instances

Instances details
Eq AxisPosn Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

clearAxes :: Plot () Source #

clear the axes of a subplot

clearAxis :: AxisType -> AxisPosn -> Plot () Source #

clear an axis of a subplot

addAxis :: AxisType -> AxisPosn -> Axis () -> Plot () Source #

add an axis to the subplot

withAxis :: AxisType -> AxisPosn -> Axis () -> Plot () Source #

operate on the given axis

BarSetting

Data Sampling

Legend

data Legend a Source #

Instances

Instances details
Applicative Legend Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

pure :: a -> Legend a #

(<*>) :: Legend (a -> b) -> Legend a -> Legend b #

liftA2 :: (a -> b -> c) -> Legend a -> Legend b -> Legend c #

(*>) :: Legend a -> Legend b -> Legend b #

(<*) :: Legend a -> Legend b -> Legend a #

Functor Legend Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

fmap :: (a -> b) -> Legend a -> Legend b #

(<$) :: a -> Legend b -> Legend a #

Monad Legend Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(>>=) :: Legend a -> (a -> Legend b) -> Legend b #

(>>) :: Legend a -> Legend b -> Legend b #

return :: a -> Legend a #

clearLegend :: Plot () Source #

clear the legend

setLegend :: LegendBorder -> LegendLocation -> LegendOrientation -> Plot () Source #

set the legend location and orientation

withLegendFormat :: Text () -> Plot () Source #

format the legend text

Formatting

data Tick Source #

Constructors

Minor 
Major 

Instances

Instances details
Eq Tick Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(==) :: Tick -> Tick -> Bool #

(/=) :: Tick -> Tick -> Bool #

setTicks :: Tick -> TickValues -> Axis () Source #

format the axis ticks

setGridlines :: Tick -> GridLines -> Axis () Source #

should gridlines be displayed?

setTickLabelFormat :: TickFormat -> Axis () Source #

set the tick label format

setTickLabels :: [String] -> Axis () Source #

a list of data labels

withTickLabelsFormat :: Text () -> Axis () Source #

format the tick labels

withAxisLabel :: Text () -> Axis () Source #

operate on the axis label

withAxisLine :: Line () -> Axis () Source #

format the axis line

withGridLine :: Tick -> Line () -> Axis () Source #

format the grid lines

Lines

data Line a Source #

Instances

Instances details
Applicative Line Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

pure :: a -> Line a #

(<*>) :: Line (a -> b) -> Line a -> Line b #

liftA2 :: (a -> b -> c) -> Line a -> Line b -> Line c #

(*>) :: Line a -> Line b -> Line b #

(<*) :: Line a -> Line b -> Line a #

Functor Line Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

fmap :: (a -> b) -> Line a -> Line b #

(<$) :: a -> Line b -> Line a #

Monad Line Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(>>=) :: Line a -> (a -> Line b) -> Line b #

(>>) :: Line a -> Line b -> Line b #

return :: a -> Line a #

PlotFormats Line Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

modifyFormat :: Line () -> DecoratedSeries -> Data DecoratedSeries

class LineFormat a Source #

Minimal complete definition

toLine

Instances

Instances details
LineFormat DashStyle Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Line

Methods

toLine :: (MonadReader Options m, MonadSupply SupplyData m) => DashStyle -> m LineType

LineFormat LineWidth Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Line

Methods

toLine :: (MonadReader Options m, MonadSupply SupplyData m) => LineWidth -> m LineType

Real a => LineFormat (Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Line

Methods

toLine :: (MonadReader Options m, MonadSupply SupplyData m) => Colour a -> m LineType

Real a => LineFormat (DashStyle, Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Line

Methods

toLine :: (MonadReader Options m, MonadSupply SupplyData m) => (DashStyle, Colour a) -> m LineType

LineFormat (DashStyle, LineWidth) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Line

Methods

toLine :: (MonadReader Options m, MonadSupply SupplyData m) => (DashStyle, LineWidth) -> m LineType

Real a => LineFormat (LineWidth, Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Line

Methods

toLine :: (MonadReader Options m, MonadSupply SupplyData m) => (LineWidth, Colour a) -> m LineType

Real a => LineFormat (DashStyle, LineWidth, Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Line

Methods

toLine :: (MonadReader Options m, MonadSupply SupplyData m) => (DashStyle, LineWidth, Colour a) -> m LineType

data Dash Source #

Constructors

Dot 
Dash 

Instances

Instances details
Eq Dash Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(==) :: Dash -> Dash -> Bool #

(/=) :: Dash -> Dash -> Bool #

LineFormat DashStyle Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Line

Methods

toLine :: (MonadReader Options m, MonadSupply SupplyData m) => DashStyle -> m LineType

Real a => LineFormat (DashStyle, Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Line

Methods

toLine :: (MonadReader Options m, MonadSupply SupplyData m) => (DashStyle, Colour a) -> m LineType

LineFormat (DashStyle, LineWidth) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Line

Methods

toLine :: (MonadReader Options m, MonadSupply SupplyData m) => (DashStyle, LineWidth) -> m LineType

Real a => LineFormat (DashStyle, LineWidth, Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Line

Methods

toLine :: (MonadReader Options m, MonadSupply SupplyData m) => (DashStyle, LineWidth, Colour a) -> m LineType

clearLineFormat :: Line () Source #

clear the formatting of a line

setDashStyle :: DashStyle -> Line () Source #

change the dash style of a line

setLineWidth :: LineWidth -> Line () Source #

change the line width of a line

setLineColour :: Color -> Line () Source #

change the line colour of a line

Points

data Point a Source #

Instances

Instances details
Applicative Point Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

pure :: a -> Point a #

(<*>) :: Point (a -> b) -> Point a -> Point b #

liftA2 :: (a -> b -> c) -> Point a -> Point b -> Point c #

(*>) :: Point a -> Point b -> Point b #

(<*) :: Point a -> Point b -> Point a #

Functor Point Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

fmap :: (a -> b) -> Point a -> Point b #

(<$) :: a -> Point b -> Point a #

Monad Point Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(>>=) :: Point a -> (a -> Point b) -> Point b #

(>>) :: Point a -> Point b -> Point b #

return :: a -> Point a #

PlotFormats Point Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

modifyFormat :: Point () -> DecoratedSeries -> Data DecoratedSeries

class PointFormat a Source #

Minimal complete definition

toPoint

Instances

Instances details
PointFormat Glyph Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Point

Methods

toPoint :: (MonadReader Options m, MonadSupply SupplyData m) => Glyph -> m PointType

Real a => PointFormat (Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Point

Methods

toPoint :: (MonadReader Options m, MonadSupply SupplyData m) => Colour a -> m PointType

Real a => PointFormat (Glyph, Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Point

Methods

toPoint :: (MonadReader Options m, MonadSupply SupplyData m) => (Glyph, Colour a) -> m PointType

PointFormat (Glyph, PointSize) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Point

Methods

toPoint :: (MonadReader Options m, MonadSupply SupplyData m) => (Glyph, PointSize) -> m PointType

Real a => PointFormat (Glyph, PointSize, Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Point

Methods

toPoint :: (MonadReader Options m, MonadSupply SupplyData m) => (Glyph, PointSize, Colour a) -> m PointType

data Glyph Source #

Instances

Instances details
PointFormat Glyph Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Point

Methods

toPoint :: (MonadReader Options m, MonadSupply SupplyData m) => Glyph -> m PointType

Real a => PointFormat (Glyph, Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Point

Methods

toPoint :: (MonadReader Options m, MonadSupply SupplyData m) => (Glyph, Colour a) -> m PointType

PointFormat (Glyph, PointSize) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Point

Methods

toPoint :: (MonadReader Options m, MonadSupply SupplyData m) => (Glyph, PointSize) -> m PointType

Real a => PointFormat (Glyph, PointSize, Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Point

Methods

toPoint :: (MonadReader Options m, MonadSupply SupplyData m) => (Glyph, PointSize, Colour a) -> m PointType

setGlyph :: Glyph -> Point () Source #

change the glyph of a point

setPointSize :: PointSize -> Point () Source #

change the size of a point

setPointColour :: Color -> Point () Source #

change the colour of a point

Bars

data Bar a Source #

Instances

Instances details
Applicative Bar Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

pure :: a -> Bar a #

(<*>) :: Bar (a -> b) -> Bar a -> Bar b #

liftA2 :: (a -> b -> c) -> Bar a -> Bar b -> Bar c #

(*>) :: Bar a -> Bar b -> Bar b #

(<*) :: Bar a -> Bar b -> Bar a #

Functor Bar Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

fmap :: (a -> b) -> Bar a -> Bar b #

(<$) :: a -> Bar b -> Bar a #

Monad Bar Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(>>=) :: Bar a -> (a -> Bar b) -> Bar b #

(>>) :: Bar a -> Bar b -> Bar b #

return :: a -> Bar a #

PlotFormats Bar Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Plot.Data

Methods

modifyFormat :: Bar () -> DecoratedSeries -> Data DecoratedSeries

class BarFormat a Source #

Minimal complete definition

toBar

Instances

Instances details
Real a => BarFormat (Colour a) Source # 
Instance details

Defined in Graphics.Rendering.Plot.Figure.Bar

Methods

toBar :: (MonadReader Options m, MonadSupply SupplyData m) => Colour a -> m BarType

clearBarFormat :: Bar () Source #

clear the formatting of a line

setBarWidth :: Width -> Bar () Source #

set the width of the bar

setBarColour :: Color -> Bar () Source #

set the colour of the bar

setBarBorderWidth :: LineWidth -> Bar () Source #

set the width of the bar border

setBarBorderColour :: Color -> Bar () Source #

set the colour of the bar border

Text labels

data Text a Source #

Instances

Instances details
Applicative Text Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

pure :: a -> Text a #

(<*>) :: Text (a -> b) -> Text a -> Text b #

liftA2 :: (a -> b -> c) -> Text a -> Text b -> Text c #

(*>) :: Text a -> Text b -> Text b #

(<*) :: Text a -> Text b -> Text a #

Functor Text Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

fmap :: (a -> b) -> Text a -> Text b #

(<$) :: a -> Text b -> Text a #

Monad Text Source # 
Instance details

Defined in Graphics.Rendering.Plot.Types

Methods

(>>=) :: Text a -> (a -> Text b) -> Text b #

(>>) :: Text a -> Text b -> Text b #

return :: a -> Text a #

A text element must exist for formatting to work

clearText :: Text () Source #

clear the text entry

clearTextFormat :: Text () Source #

set the text formatting to the default

setText :: String -> Text () Source #

set the value of a text entry

setFontFamily :: FontFamily -> Text () Source #

set the font style of a text entry

setFontStyle :: FontStyle -> Text () Source #

set the font style of a text entry

setFontVariant :: Variant -> Text () Source #

set the font variant of a text entry

setFontWeight :: Weight -> Text () Source #

set the font weight of a text entry

setFontStretch :: Stretch -> Text () Source #

set the font stretch of a text entry

setFontSize :: FontSize -> Text () Source #

set the font size of a text entry

setFontColour :: Color -> Text () Source #

set the colour of a text entry