-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dimensional counters #22
Dimensional counters #22
Conversation
Breaking change: the Sample type now holds dimensions as key-value pairs.
This change breaks consumers of the API, and maybe some old GHC/Base versions. (Built with I plan to wrap the new module with a type-fancy layer (either in this package or in another package) for a stronger guarantee that the dimensions passed to Minimal compatibility patches to demonstrate the feature are provided for
The example works and displays individual curves flattening the dimensions as follows. I'm more interested in providing support into |
@tibbe any comment about this MR? I'm willing to provide a typeful layer above this one to enforce more type-safety between the construction and consuming sides, though it should probably go in another package where we can allow stricter GHC versions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@23Skidoo is the main reviewer now but I added some comments.
type Point = [Text] | ||
|
||
data Dimensional a = Dimensional { | ||
_create :: !(IO a) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please stick to the field naming pattern used for other data types (i.e. no leading underscore, but prefixed as needed).
type Label = Dimensional Label.Label | ||
type Distribution = Dimensional Distribution.Distribution | ||
|
||
example :: IO () |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This belongs in the examples/ directory and/or in some docs.
import Data.HashMap.Strict (HashMap, empty) | ||
import qualified Data.HashMap.Strict as HashMap | ||
|
||
type Name = Text |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lots of Haddoc docs needed here.
@@ -0,0 +1,88 @@ | |||
{-# LANGUAGE LambdaCase #-} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file needs some top-level Haddocks explaining how to use this module and what it's for.
Closing in favour of #32. |
Thanks @matth- |
No description provided.