My following vega code correctly displays the actual chart and legend. However, I have been trying to get tooltip to display some data but the tooltips are not showing at all. Here is my latest code
{
"$schema": "https://vega.github.io/schema/vega/v4.0.json",
"title": "Top 10 IP Addresses",
"data": [
{
"name": "table",
"url": {
"%context%": "true",
"%timefield%": "@timestamp",
"index": "alb-logs-*",
"body": {
"aggs": {
"TopIP": {
"terms": {
"field": "elb_client_ip"
}
}
}
},
"size": 0
},
"format": {
"property": "aggregations.TopIP.buckets",
"as": "values"
},
"transform": [
{
"type": "pie",
"field": "doc_count"
}
]
}
],
"legends": [
{
"orient": "top-right",
"stroke": "color",
"title": "Origin",
"encode": {
"symbols": {
"update": {
"fill": {"value": ""},
"strokeWidth": {"value": 2},
"size": {"value": 64}
}
}
}
}
],
"scales": [
{
"name": "color",
"type": "ordinal",
"domain": {
"data": "table",
"field": "key"
},
"range": {
"scheme": "category20"
}
}
],
"marks": [
{
"type": "arc",
"from": {
"data": "table"
},
"encode": {
"enter": {
"fill": {
"scale": "color",
"field": "key"
},
"startAngle": {
"field": "startAngle"
},
"endAngle": {
"field": "endAngle"
},
"x": {
"signal": "width / 2"
},
"y": {
"signal": "height / 2"
},
"outerRadius": {
"signal": "min(width,height)/2.2"
},
"tooltip": {"signal": "datum.datum"}
}
}
}
]
}
What am I missing?