Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
30
igDataChart with two dimensional legend
posted

I want to create a scatter data chart with two dimensional legend.

For Edit fiddle - JSFiddle - Code Playground it will generate with single dimensional like below

For the custom data

[{
    Country: "US",
    Element: "A",
    Population: 197,
    Population_Unit: "1,000,000 People",
    Value: 94323,
    Value_Unit: "1,000,000 Int. $",
    Year: 1964
  }, {
    Country: "US",
    Element: "A",
    Population: 194,
    Population_Unit: "1,000,000 People",
    Value: 93700,
    Value_Unit: "1,000,000 Int. $",
    Year: 1963
  }, {
    Country: "USA",
    Element: "B",
    Population: 191,
    Population_Unit: "1,000,000 People",
    Value: 90275,
    Value_Unit: "1,000,000 Int. $",
    Year: 1962
  }, {
    Country: "USA",
    Element: "A",
    Population: 189,
    Population_Unit: "1,000,000 People",
    Value: 89816,
    Value_Unit: "1,000,000 Int. $",
    Year: 1961
  }]

How to custom the legend to achieve it based on Country & ElementA to show like below which show as table:

Its result show Country  as first column and show Element as first row and then draw different graph for different county and different color for different Element.

Parents
  • 740
    Offline posted

    Hello Edward,

    I have been looking into your question and regarding the following:

    How to custom the legend to achieve it based on Country & ElementA to show like below which show as table:

    I assume that an image that describes the desired result should be shown below this sentence, however, it seems that it is not attached.

    Having this in mind, to ensure that your question is addressed correctly, could you please provide further details on the exact requirements? If possible, it would be great if you could try to attach the image again.

    Additionally, I have prepared a small sample trying to demonstrate a possible configuration and it could be found here.

    Please let me know if this is an accurate demonstration of what you are trying to achieve.

    Looking forward to your reply.

    Sincerely,
    Riva Ivanova
    Software Developer

Reply Children