I have this chart where I have 2 lines, one which is the projected amount and one that represents the actual amount. However, since there te real amount is not yet at the final date after the last date with numbers it goes back down to 0. I wanted to know if there was a way to make sure the line stops at the last availabe real number or if there is a way to make it clear that is the last put number.
I had a go using AI component (right) compared to Glide’s chart (left).
I used JSON to gather my values into a structured format.
Then, in my users table (you can theoretically do this anywhere you need), have a combo of joined list and template column to join them together.
Then my AI component looks like this.
Schema of my inputData:
{
"$schema": "http://json-schema.org/draft-07/schema#",
"type": "array",
"items": {
"type": "object",
"properties": {
"ID": {
"type": "string"
},
"Value 1": {
"type": "integer"
},
"Value 2": {
"type": "integer"
}
},
"required": [
"ID",
"Value 1"
],
"additionalProperties": false
}
}
Use ChartJS to have line charts with X-axis being ID, and Y-axis drawing 2 lines for Value 1 and Value 2. If the value is 0, still draw from it and don't leave the line empty, unless the value is actually empty.
2 Likes