Hello,
The X-axis values are ordered Alphabetically (Ascending), but the visualization is incorrect (see image attached):
Here is the visState:
{
"title": "Characters damages per a day after registration",
"type": "line",
"params": {
"addLegend": true,
"addTimeMarker": false,
"addTooltip": true,
"categoryAxes": [
{
"id": "CategoryAxis-1",
"labels": {
"filter": true,
"show": true,
"truncate": 100,
"rotate": 0
},
"position": "bottom",
"scale": {
"type": "linear"
},
"show": true,
"style": {},
"title": {},
"type": "category"
}
],
"dimensions": {
"x": {
"accessor": 1,
"format": {
"id": "terms",
"params": {
"id": "number",
"otherBucketLabel": "Other",
"missingBucketLabel": "Missing"
}
},
"params": {},
"aggType": "terms"
},
"y": [
{
"accessor": 2,
"format": {
"id": "number"
},
"params": {},
"aggType": "avg"
},
{
"accessor": 3,
"format": {
"id": "number"
},
"params": {},
"aggType": "avg"
}
],
"splitRow": [
{
"accessor": 0,
"format": {
"id": "terms",
"params": {
"id": "string",
"otherBucketLabel": "Other",
"missingBucketLabel": "Missing"
}
},
"params": {},
"aggType": "terms"
}
]
},
"grid": {
"categoryLines": false,
"valueAxis": "ValueAxis-1"
},
"labels": {
"show": true
},
"legendPosition": "top",
"orderBucketsBySum": false,
"radiusRatio": 75,
"seriesParams": [
{
"data": {
"id": "1",
"label": "Damage dealt"
},
"drawLinesBetweenPoints": true,
"interpolate": "linear",
"mode": "normal",
"show": "true",
"showCircles": true,
"type": "histogram",
"valueAxis": "ValueAxis-1"
},
{
"data": {
"id": "2",
"label": "Damage received"
},
"drawLinesBetweenPoints": true,
"interpolate": "linear",
"mode": "normal",
"show": true,
"showCircles": true,
"type": "histogram",
"valueAxis": "ValueAxis-1"
}
],
"times": [],
"type": "line",
"valueAxes": [
{
"id": "ValueAxis-1",
"labels": {
"filter": false,
"rotate": 0,
"show": true,
"truncate": 100
},
"name": "LeftAxis-1",
"position": "left",
"scale": {
"defaultYExtents": false,
"mode": "normal",
"type": "linear"
},
"show": true,
"style": {},
"title": {
"text": "Average damage_dealt_amount"
},
"type": "value"
}
],
"thresholdLine": {
"show": false,
"value": 10,
"width": 1,
"style": "full",
"color": "#34130C"
}
},
"aggs": [
{
"id": "1",
"enabled": true,
"type": "avg",
"schema": "metric",
"params": {
"field": "damage_dealt_amount",
"customLabel": "Damage dealt"
}
},
{
"id": "2",
"enabled": true,
"type": "avg",
"schema": "metric",
"params": {
"field": "damage_received_amount",
"customLabel": "Damage received"
}
},
{
"id": "3",
"enabled": true,
"type": "terms",
"schema": "segment",
"params": {
"field": "days_after_registration",
"orderBy": "_key",
"order": "asc",
"size": 99999,
"otherBucket": true,
"otherBucketLabel": "Other",
"missingBucket": true,
"missingBucketLabel": "Missing"
}
},
{
"id": "4",
"enabled": true,
"type": "terms",
"schema": "split",
"params": {
"field": "character_name.keyword",
"orderBy": "_key",
"order": "asc",
"size": 12,
"otherBucket": true,
"otherBucketLabel": "Other",
"missingBucket": true,
"missingBucketLabel": "Missing",
"row": true
}
}
]
}
What's the problem?