plot-light-examples 0.1.0.0 → 0.2.0.0
raw patch · 5 files changed
+35/−9 lines, 5 filesdep +plot-light-examplesdep ~plot-light
Dependencies added: plot-light-examples
Dependency ranges changed: plot-light
Files
- app/heatmap/Main.hs +7/−3
- app/scatter/Main.hs +3/−1
- app/timeseries/Main.hs +2/−0
- plot-light-examples.cabal +16/−5
- src/Data/Parsers.hs +7/−0
app/heatmap/Main.hs view
@@ -4,7 +4,6 @@ -- import Data.Ratio import Graphics.Rendering.Plot.Light-import Graphics.Rendering.Plot.Light.PlotTypes import qualified Data.Attoparsec.Text as A import qualified Data.Text as T @@ -15,9 +14,8 @@ import qualified Data.Colour.Names as C import qualified Data.Colour as C--- import qualified Data.Colour.Palette.BrewerSet as CP--- import qualified Data.Colour.Palette.Harmony as CH +import Data.Parsers fname = "data/heatmap-bw" @@ -94,3 +92,9 @@ -- | parse a grid of numbers, separated by `sep` gridNum :: A.Parser s -> A.Parser [[Scientific]] gridNum sep = A.sepBy (rowNums sep) A.endOfLine++++++
app/scatter/Main.hs view
@@ -10,7 +10,9 @@ import Text.Blaze.Svg.Renderer.String (renderSvg) import Graphics.Rendering.Plot.Light-import Graphics.Rendering.Plot.Light.PlotTypes+import Graphics.Rendering.Plot.Light.Internal.Geometry++import Data.Parsers xPlot = 400 yPlot = 300
app/timeseries/Main.hs view
@@ -17,6 +17,8 @@ import Control.Applicative ((<|>)) import Data.Time (Day, TimeOfDay) +import Data.Parsers+ fname = "data/forex" xPlot = 400
plot-light-examples.cabal view
@@ -1,5 +1,5 @@ name: plot-light-examples-version: 0.1.0.0+version: 0.2.0.0 synopsis: Example binaries for plot-light description: Example binaries for plot-light homepage: https://github.com/ocramz/plot-light-examples@@ -12,18 +12,27 @@ build-type: Simple extra-source-files: README.md cabal-version: >=1.10-tested-with: GHC == 8.0.2, GHC == 8.4.1+tested-with: GHC == 8.0.2, GHC == 8.2.2 data-dir: data data-files: forex heatmap-bw +library+ default-language: Haskell2010+ ghc-options: -Wall -Wno-missing-signatures -Wno-type-defaults -Wno-name-shadowing+ hs-source-dirs: src+ exposed-modules: Data.Parsers+ build-depends: base >= 4.7 && < 5+ , attoparsec+ executable scatter default-language: Haskell2010 ghc-options: -threaded -rtsopts -with-rtsopts=-N hs-source-dirs: app/scatter main-is: Main.hs build-depends: base >= 4.7 && < 5- , plot-light >= 0.2.9+ , plot-light > 0.3.2+ , plot-light-examples , attoparsec , text , colour@@ -36,7 +45,8 @@ hs-source-dirs: app/timeseries main-is: Main.hs build-depends: base >= 4.7 && < 5- , plot-light >= 0.2.9+ , plot-light > 0.3.2+ , plot-light-examples , attoparsec , attoparsec-time >= 1 , time@@ -51,7 +61,8 @@ hs-source-dirs: app/heatmap main-is: Main.hs build-depends: base >= 4.7 && < 5- , plot-light >= 0.2.9+ , plot-light > 0.3.2+ , plot-light-examples , attoparsec , time , text
+ src/Data/Parsers.hs view
@@ -0,0 +1,7 @@+module Data.Parsers where++import qualified Data.Attoparsec.Text as A++space, comma :: A.Parser Char+space = A.char ' '+comma = A.char ','