You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a question rather than a bug. I am a happy hvega user but my code usually gets bloated up at the point where I need to convert some Haskell data type into an HVega datatype.
dataFromRows expects a [DataRow] which can be constructed with dataRow. However, this constructor doesn't have the typical form [(FieldName, DataValue)] -> [DataRow] that one would expect and that could be used with a simple dataRow <$> myrows to convert a whole list of fields with associated value into a list of DataRows.
I don't understand the point of this other constructor yet. Yes it allows us to concatenate lists of DataRows but wouldn't we be able to do this with simple list operators anyway?
What are the objections against simple dataRow :: [(FieldName, DataValue)] -> [DataRow] and dataColumn :: FieldName -> [DataValue] -> [DataRow] constructors that I would expect?
The text was updated successfully, but these errors were encountered:
So, this is code I based on the Elm Vega Lite version and haven't really looked at since (to see if it can be made "more" haskelly, to abuse a term or two).
This is a question rather than a bug. I am a happy hvega user but my code usually gets bloated up at the point where I need to convert some Haskell data type into an HVega datatype.
dataFromRows
expects a[DataRow]
which can be constructed withdataRow
. However, this constructor doesn't have the typical form[(FieldName, DataValue)] -> [DataRow]
that one would expect and that could be used with a simpledataRow <$> myrows
to convert a whole list of fields with associated value into a list of DataRows.I don't understand the point of this other constructor yet. Yes it allows us to concatenate lists of DataRows but wouldn't we be able to do this with simple list operators anyway?
What are the objections against simple
dataRow :: [(FieldName, DataValue)] -> [DataRow]
anddataColumn :: FieldName -> [DataValue] -> [DataRow]
constructors that I would expect?The text was updated successfully, but these errors were encountered: