Sandeep Rao
Sandeep Rao

Reputation: 1

Area with field [Dates], type Temporal on X & Y axis

According to Vegalite AREA, Area works for X as temporal or ordinal field and Y as quantitative only. I have large dataset that consists of mainly 3 columns, Milestone ID, update Date and Targets (Date). I have generated the chart using Deneb/PowerBI and Vegalite (see below first snapshot - Current Working Chart). Along with this, I want to generate the Area using the same fields (on both X and Y axis) which are temporal type. which I am unable to generate.

Current Working Chart

I have tried adding area using __row__ (from DENEB) and IndexColumn (using transform, calculate __row__ as IndexColumn) into the existing layer. It did not come as expected. The mark line (with points: true) should not enter into the area shaded zone. It should be above the shaded zone (area) as above.

AREA Error

here's the link to pbix file and sample xlsx data Data Link

Upvotes: 0

Views: 52

Answers (1)

APB Reports
APB Reports

Reputation: 2441

If you want the Area layer to appear under the lines then it should be the first layer in the spec. Vega lite stacks layers on top of each other based on their order in the spec.

enter image description here

Upvotes: 0

Related Questions