Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7913745
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T13:54:53+00:00 2026-06-03T13:54:53+00:00

I am a beginner in JSCharts. I’m using $.getJSON to load json files and

  • 0

I am a beginner in JSCharts. I’m using $.getJSON to load json files and
with them i want to create charts with JSCharts. I am getting the message:

JSChart: Input data in wrong format for selected chart type

 var x= new Array();

 $.getJSON('test.json', function(data) {

  $.each(data, function(key, val) {

  x.push(val[0].abs);
  x.push(val[1].ord)
});
 });

var myChart = new JSChart('chartcontainer', 'line');
myChart.setDataArray(x);
myChart.draw();

Any ideas how to change to format, so it can be accepted by jscharts?

Even if i pass them as integers they are not accepted.
Json looks like this:

   " cordonnee " : [ { " abs " : "45" } ,
                     { " ord " : "12" }
                   ],

     "autre" : [ { "abs": "68" } ,
                 { " ord " : "13" }
               ]

Thank you

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T13:54:55+00:00Added an answer on June 3, 2026 at 1:54 pm

    Try to parse the values as Integers.

    $.each(data, function(key, val) {
    
      x.push(parseInt(val[0].abs));
      x.push(parseInt(val[1].ord));
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Complete beginner here. I want to create a new tab on each page that
Iam beginner to windows services , i have a console application to transfer files
(Beginner to HTML) I have made a Photoshop mock-up of the website I want
Python beginner here. I am using the matplotlib library to make graphs from tab
Beginner question here! look at picture, I want the butten-edittext-button to fill the width
Beginner android question. Ok, I've successfully written files. E.g. // get the file name
iOS beginner here. I'm using the following code to save my facebook accessToken and
very beginner question. I am using Rails 3's query interface as shown: class User
Beginner question -- what do you usually use as a multimap? I want a
(Lisp beginner) I need to create a 2D array, and initialize each cell in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.