Forum Discussion
Visual simultaneous events
Thanks Pragati11 Greg_Deckler TomMartens
mahoneypat thanks for the offer. I'm attaching some sample data with the start and end times for the events per user. Users timelines should be depicted one above the other along the y axis as in the pic on my initial post.
Thanks a lot
- mahoneypat4 years agoMicrosoft Employee
I missed that you had start/end times, so used a "rect" mark instead (so an "x2" value could be provided). How does this look? If it works, the "spec" is below that you can copy/paste into your Deneb visual. There is a lot more you can do with the formatting of course.
{
"data": {"name": "dataset"},
"mark": {"type": "rect"},
"encoding": {
"y": {
"field": "User",
"type": "nominal",
"axis": {"title": null}
},
"x": {
"field": "StartDateTime",
"type": "temporal",
"axis": {"title": "DateTime"}
},
"x2": {"field": "EndDateTime"}
}
}
Pat