You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by "skczjun (via GitHub)" <gi...@apache.org> on 2025/03/07 08:14:02 UTC

[I] [Bug] 雷达图空值当成了0来处理 [echarts]

skczjun opened a new issue, #20811:
URL: https://github.com/apache/echarts/issues/20811

   ### Version
   
   5.2.2
   
   ### Link to Minimal Reproduction
   
   https://echarts.apache.org/examples/zh/editor.html?c=line-simple
   
   ### Steps to Reproduce
   
   option = {
      radar: {
       // shape: 'circle',
       indicator: [
         { name: 'Sales', max: 400 },
         { name: 'Administration', max: 400 },
         { name: 'Information Technology', max: 400 },
         { name: 'Customer Support', max: 400 },
         { name: 'Development', max: 400 },
         { name: 'Marketing', max: 400 }
       ]
     },
     series: [
       {
         type: 'radar',
         data: [
           {value: [150, undefined , 224, null, 135, 50]}
           ]
       }
     ]
   };
   
   ### Current Behavior
   
   null,undefined当成了0来处理。
   
   ### Expected Behavior
   
   null,undefined直接按空值来处理,连线断开
   
   ### Environment
   
   ```markdown
   - OS:
   - Browser:
   - Framework:
   ```
   
   ### Any additional comments?
   
   _No response_


-- 
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-unsubscribe@echarts.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] 雷达图空值当成了0来处理 [echarts]

Posted by "Ovilia (via GitHub)" <gi...@apache.org>.
Ovilia commented on issue #20811:
URL: https://github.com/apache/echarts/issues/20811#issuecomment-2720369498

   The above demo seems reasonable. Thanks for suggestion. If you are interested, you are welcomed to make a pull request so that this problem can get fixed earlier. Thanks!


-- 
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-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] 雷达图空值当成了0来处理 [echarts]

Posted by "skczjun (via GitHub)" <gi...@apache.org>.
skczjun commented on issue #20811:
URL: https://github.com/apache/echarts/issues/20811#issuecomment-2716076484

   Normally, a radar chart includes specific indicators. However, in certain cases, some indicators may not be available and thus have null values. These should not be simply treated as 0 because doing so would make it impossible to distinguish between actual zero values and missing data, which could represent anomalies. Given this issue, a new component library has been adopted to display the radar chart in order to better handle such scenarios where indicators might be missing or unavailable.
   
   This approach ensures that missing data points are appropriately represented without conflating them with valid zero values, thereby providing clearer insights into the underlying data and making it easier to identify potential anomalies. By switching to a more capable component library, you can implement more sophisticated handling of missing data, improving the accuracy and interpretability of your radar charts.
   
   If there is a need to display null values as 0, this can be achieved by modifying the data source or by providing a toggle in the component to allow users to decide whether null values should be shown as 0. This approach avoids a one-size-fits-all solution that automatically treats all null values as 0, giving users the flexibility to handle missing data according to their specific needs.
   
   This method ensures that users can choose the most appropriate way to represent missing data, either displaying null values as 0 when it makes sense for their use case, or leaving them as null to clearly indicate the absence of data. By offering such an option, the component becomes more versatile and better suited to different data visualization requirements.


-- 
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-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] 雷达图空值当成了0来处理 [echarts]

Posted by "helgasoft (via GitHub)" <gi...@apache.org>.
helgasoft commented on issue #20811:
URL: https://github.com/apache/echarts/issues/20811#issuecomment-2707465998

   duplicate od #20654
   > Expected Behavior:   null and undefined are directly treated as null values, and the connection is disconnected
   
   Disconnecting lines in a radar chart would make it hard to read, I think. Maybe connecting to the next valid point would be more preferable, like so:
   ![Image](https://github.com/user-attachments/assets/63ecfce4-2ea9-4af9-899b-9e2378e72e91)


-- 
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-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] 雷达图空值当成了0来处理 [echarts]

Posted by "skczjun (via GitHub)" <gi...@apache.org>.
skczjun commented on issue #20811:
URL: https://github.com/apache/echarts/issues/20811#issuecomment-2709162250

   > duplicate od [#20654](https://github.com/apache/echarts/issues/20654)
   > 
   > > Expected Behavior:   null and undefined are directly treated as null values, and the connection is disconnected
   > 
   > Disconnecting lines in a radar chart would make it hard to read, I think. Maybe connecting to the next valid point would be more preferable, like so: ![Image](https://github.com/user-attachments/assets/63ecfce4-2ea9-4af9-899b-9e2378e72e91)
   
   "How to achieve this effect"


-- 
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-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] 雷达图空值当成了0来处理 [echarts]

Posted by "echarts-bot[bot] (via GitHub)" <gi...@apache.org>.
echarts-bot[bot] commented on issue #20811:
URL: https://github.com/apache/echarts/issues/20811#issuecomment-2705802511

   @skczjun It seems you are not using English, I've helped translate the content automatically. To make your issue understood by more people and get helped, we'd like to suggest using English next time. 🤗
   <details><summary><b>TRANSLATED</b></summary><br>
   
   **TITLE**
   
   [Bug] The null value of the radar chart is treated as 0
   </details>


-- 
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-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] 雷达图空值当成了0来处理 [echarts]

Posted by "Ovilia (via GitHub)" <gi...@apache.org>.
Ovilia commented on issue #20811:
URL: https://github.com/apache/echarts/issues/20811#issuecomment-2709360006

   Consider using line series in polar system if you want to "connect to the next valid point" because if you have such requirement, your use case may probably not a "radar series".


-- 
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-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] null value for radar series [echarts]

Posted by "tianrking (via GitHub)" <gi...@apache.org>.
tianrking commented on issue #20811:
URL: https://github.com/apache/echarts/issues/20811#issuecomment-5348687947

   I'd like to work on this.
   
   I plan to reproduce the current behavior on `master`, trace the radar data/layout/rendering path so missing dimensions are preserved instead of becoming indistinguishable from real zero values, and add both logic-level and browser/visual regressions covering `null`/missing values, real zeroes, multiple series, symbols, areas, and tooltip data. I will keep the change compatible with existing radar data that contains only numeric values and run the repository's unit, type, lint, DTS, build, and relevant visual checks before opening a PR.
   
   AI assistance disclosure: I am using OpenAI Codex for code exploration and implementation assistance; I will review, understand, and test the complete change.


-- 
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-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] 雷达图空值当成了0来处理 [echarts]

Posted by "Ovilia (via GitHub)" <gi...@apache.org>.
Ovilia commented on issue #20811:
URL: https://github.com/apache/echarts/issues/20811#issuecomment-2709356528

   I think "connecting to the next valid point" should be misleading, especially when symbol size is small. From the definition of Radar series, where each indicator shows the value of a dimension, I think it's reasonable to display 0 for dimensions not available. So I would say this is "not-a-bug".


-- 
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-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] 雷达图空值当成了0来处理 [echarts]

Posted by "skczjun (via GitHub)" <gi...@apache.org>.
skczjun commented on issue #20811:
URL: https://github.com/apache/echarts/issues/20811#issuecomment-2719457252

   ![Image](https://github.com/user-attachments/assets/8dbb14b3-54a2-4cb5-856d-b158e7be7034)
   This is the only reasonable display


-- 
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-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


Re: [I] [Bug] null value for radar series [echarts]

Posted by "helgasoft (via GitHub)" <gi...@apache.org>.
helgasoft commented on issue #20811:
URL: https://github.com/apache/echarts/issues/20811#issuecomment-4963591616

   > "How to achieve this effect?"  - @skczjun 
   
   A [Demo](https://echarts.apache.org/examples/en/editor.html?code=fVNNi9swEL37V8ylKGG92SS7oeCQQmihFNpSmr2FHBR74ojIkpHkNG7If-9IslMXyvpgNB_vzZsZ6ekJaoPOCTSPolTaYJJrZR0Ih5WFFWwTYBsu0bIU2LqohBLWGe6EVixlX9RBmypY8Ir5UWmpy5YCHxvrdIUGNk1da-M8-hOeUeq6QhXMb9yc0AlVst2yK3rmMtScLaYpzGazFObzlxRUIyXZz4t4BMpPCu44pXrEpOL1CEbncyrGsPoAW3_awXiZhCYmdWOPI8bI9qBo-tN2uiNfousgfwXXBMAJJzELRzLw4jJgP7TkBkQlHDWqSvjJC24YZdxS-kksURUE8QiJB48wojw61iXUHu7jhheisRR-P33HQshpLZ2o-3q0jDhOhwRg1_zGfBYMvYdG5UHvqOaGV3bcYQFojY0hP8TAhEbTIPUID8BAKPo9xK1u_0mY7cKoPMOt74mrUuL6IkhsZPfjyiI6KtrrRtEU2s-c1B9oCRj9tpbCfRXqPkNyHfWvDJxpMBaJiZzY_5cXuIaJNNy1l5M9Ps9nk0UvMQ6z0wghs-KXDOZ0dd5UOCg8LHlLQ-RV5CeKhEDn_4vie5R32ICS1Gi6G0T54vUNBmnRCCSF9Iro6ztVvKJcduAn9H3QZep5XFv7iCR99ES4Qb5xLfV-JXn0RBTm7ju9AGL08-xRudamEIoUbFpLOyKGcOnutLat9lpuxG8ip1fVef1S73J3yW35Bw&enc=deflate) on how to handle missing values with a **polar** chart.
   <img width="501" height="422" alt="Image" src="https://github.com/user-attachments/assets/cc999c15-c9f1-4421-a7f6-7e4bf048dbe2" />


-- 
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-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org