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
Is it possible to add possibility to plot multiple values from a single data type.
For example, I'm working on a toy example that shows history of git diffs over time.
Data type is as follows:
type alias Delta =
{ author : Author
, commit : Commit
, summary : Summary
, time : Time
, additions : Int
, deletions : Int
}
But viewCustom does not allow this to be plotted directly, it expects x and y.
So I have to first make 2 lists containing (Time, Float) for the additions and deletions.
...
chartConfig : GraphModel -> LineChart.Config (Time.Time, Int) GraphMsg
chartConfig model =
{ x = Axis.time 1270 "Time" Tuple.first
, y = Axis.default 450 "LOC" (Tuple.second >> toFloat)
...
This is all fine for plotting, but when I try to show hover data.. most information is now lost.
I have a workaround, but it involves me keeping track of a Dict Time Delta and it's noticably slower for large repositories.
Ideally, it should be possible to have chartConfig : GraphModel -> LineChart.Config Delta GraphMsg;
giving me full access to the data.
Any chance this could be integrated into the library? Or does anyone know a better way of dealing with this kind of data?
The text was updated successfully, but these errors were encountered:
Hi,
Is it possible to add possibility to plot multiple values from a single data type.
For example, I'm working on a toy example that shows history of git diffs over time.
Data type is as follows:
But
viewCustom
does not allow this to be plotted directly, it expectsx
andy
.So I have to first make 2 lists containing (Time, Float) for the additions and deletions.
This is all fine for plotting, but when I try to show hover data.. most information is now lost.
I have a workaround, but it involves me keeping track of a
Dict Time Delta
and it's noticably slower for large repositories.Ideally, it should be possible to have
chartConfig : GraphModel -> LineChart.Config Delta GraphMsg
;giving me full access to the data.
Any chance this could be integrated into the library? Or does anyone know a better way of dealing with this kind of data?
The text was updated successfully, but these errors were encountered: