Get a machine state bar chart

I also saw this here…

But it seems to reference a table rather than a machine trail and there is no mentioning how to set it up they way it intended. On the API page I only see these archive links that are terribly complicated to parse.