Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] support 2D-array data #24

Open
xiaoluoHe opened this issue Jul 3, 2023 · 0 comments
Open

[Feature] support 2D-array data #24

xiaoluoHe opened this issue Jul 3, 2023 · 0 comments

Comments

@xiaoluoHe
Copy link
Contributor

What problem does this feature solve?

support frequently used data format:

  • 2d-array:
const data = [
    ['product', '2015', '2016', '2017'],  
    ['Matcha Latte', 43.3, 85.8, 93.7],  
    ['Milk Tea', 83.1, 73.4, 55.1],  
    ['Cheese Cocoa', 86.4, 65.2, 82.5],  
    ['Walnut Brownie', 72.4, 53.9, 39.1]   
] 
  • Column based key-value format
const data = [
   'product': ['Matcha Latte', 'Milk Tea', 'Cheese Cocoa', 'Walnut Brownie'],
    'count': [823, 235, 1042, 988],
    'score': [95.8, 81.4, 91.2, 76.9]
] 
  • Row based key-value
const data = [
    {product: 'Matcha Latte', count: 823, score: 95.8},
    {product: 'Milk Tea', count: 235, score: 81.4},
    {product: 'Cheese Cocoa', count: 1042, score: 91.2},
    {product: 'Walnut Brownie', count: 988, score: 76.9}
]

What does the proposed API look like?

none

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant