im trying to create two markLines with my averages (yearly and last 13 weeks) the first markline will be my yearly average with a small tooltip position around January. My second one will be my last 13 weeks averages with a small position at around july. The screenshot below is what I have.
Here is a screenshot the small tooltip. Has to be a markline too.
Here are my options. MarkLine doesn't appear at all.
xAxis: [
{
type: "category",
data: Object.keys(resultObject),
show: false,
},
{
position: "bottom",
type: "category",
data: categories.map((category) => category.charAt(0)),
xAxisIndex: 2,
show: true,
axisLine: {
show: false,
},
axisTick: {
show: false,
},
},
],
yAxis: {
show: false,
type: "value",
},
series: [
{
data: Object.values(resultObject),
type: "bar",
itemStyle: {
color: (seriesIndex) =>
seriesIndex.dataIndex > 39 ? "#FF5630" : "#A19D9A",
},
markLine: {
data: {
name: "Horizontal line with Y value at 100",
yAxis: 100,
},
},
},
],