Using additional data fields eg text labels from same data source array as X and Y. #467
-
|
I'm trying to work out how to access what should be text from a datasource array to add to the numeric value with a text description. This is what I have tried so far. The colour is working ok, but I want the text from the How do I refer to one of these other values in a texttemplate, it only seems to see x or y and customdata doesn't seem to work as the docs suggest. I might have misunderstood that. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
|
try like this: customdata: |
$fn ({ meta }) => ({
grindex: meta.greennessForecast.map(({ greennessIndex }) => greennessIndex)
});Or customdata: |
$ex ({ grindex: meta.greennessForecast.map(({ greennessIndex }) => greennessIndex)})
|
Beta Was this translation helpful? Give feedback.



Oh, I see, there's a separate issue: you are returning an object with an array, but should return an array of objects