FLOT: Order the y axis by minimum date

2019-07-16 12:02发布

The ticks I am passing is the following:

ticks:
    0: [3, Tender Period, 2014-03-11]
    1: [1, Pre-Contract Preparation, 2014-03-17]
    2: [2, Contract Period, 2014-06-10]

Graph

But in my chart, its started with [3, Tender Period] then why my second object is [2 Contact Period] Period rather than [1 Pre-Contract Preparation]?

I don't have any idea why it is changed when it comes to the chart!

1条回答
Summer. ? 凉城
2楼-- · 2019-07-16 12:54

It's not the order but the number (first argument i.e. [3,1,2]) of the tick that gives the order. You need to renumber so you get a higher number for the earlier bar.

查看更多
登录 后发表回答