pissang commented on code in PR #16895: URL: https://github.com/apache/echarts/pull/16895#discussion_r862281213
########## src/coord/Axis.ts: ########## @@ -129,7 +129,12 @@ class Axis { fixExtentWithBands(extent, (scale as OrdinalScale).count()); } - return linearMap(data, NORMALIZED_EXTENT, extent, clamp); + if ((extent[0] === extent[1]) && (data < 0 || data > 1)) { + return data * extent[0] * 2; Review Comment: I still think the equation used here is too tricky. It heavily depends on what the data is and can't be explained when data is not -0.5 or 1.5. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@echarts.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@echarts.apache.org For additional commands, e-mail: commits-h...@echarts.apache.org