JavaScript Highcharts Multiple series with database highcharts multiple series line chart,highcharts multiple series json,highcharts

I ask for for some help since I can't find another thread to resolve my problem. I'm using HighCharts to render one chart with temperature and humidity values, saved on a local database. Each values comes with its type (temp or humi), the sensor which made the measurement, the datetime to know when it was taken, and the id of coefficients that come to calculate the real temp and humi values. What I wants to render a chart where each serie is a sensor, with the two types of values the sensor saved on my database. I can have up to 24 sensors with 24 temps and 24 humis with the same datetime in the database

First I don't know if I can do some objects definitions to use them directly in HighCharts, so for now, I have plenty of array. I don't understand the way that series options work, there are a lot of things and I'm lost. I just switched from C++ to JS and PHP so it is hard for me to change my habits ^^

Can't upload my table here, but I can host it here

If it's not possible to make only one chart, can I do two charts: one with temperatures an done with humidities in one (like with a tab?).

Thank you :)


EDIT: Here is my JSON to test the chart :

{"type":["temp","humi","temp","humi","temp","humi","temp","humi"],"capteur":["1","1","3","3","1","1","3","3"],"date":["1432654910","1432654910","1432654910","1432654910","1432742599","1432742599","1432742599","1432742599"],"valeur":["6626","1220","6357","1168","6782","1118","6329","994"],"coeff":["0","0","0","0","0","0","0","0"]}

Here my JS function to transform the JSON to the array I need :

function arrangeData(data) :

    var result = {
        "temp" : {
            "capteur" : [[], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], []], "date" : []
        }, 
        "humi" : {
            "capteur" : [[], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], [], []], "date" : []
        }
    };
    for(var i in data.type){
        if(data.type[i].localeCompare("temp") == 0){
            result.temp.capteur[data.capteur[i] - 1].push(data.valeur[i]);
            if(result.temp.date.length != 0){
                if(result.temp.date[result.temp.date.length - 1].getTime() != data.date[i] * 1000)
                    result.temp.date.push(new Date(data.date[i] * 1000));
            }
            else
                result.temp.date.push(new Date(data.date[i] * 1000));
        }
        else{
            result.humi.capteur[data.capteur[i] - 1].push(data.valeur[i]);
            if(result.humi.date.length != 0){
                if(result.humi.date[result.humi.date.length - 1].getTime() != data.date[i] * 1000)
                    result.humi.date.push(new Date(data.date[i] * 1000));
            }
            else
                result.humi.date.push(new Date(data.date[i] * 1000));
        }
    }
    console.log(result);
    return result;

And I pass the "result" to setChart like this :

setChart(chart_temp, name, data.temp.date, data.temp.capteur);

Answer:1

I have the following page <!DOCTYPE html> <html> <script type="text/javascript"> function loopLink(i) { window.open($('#iframe_a').contents().find('.image-...

I have the following page <!DOCTYPE html> <html> <script type="text/javascript"> function loopLink(i) { window.open($('#iframe_a').contents().find('.image-...

My app works fine on browser but doesn't render the google map on emulator. This app is based on an exisiting app that already has a google map working fine on emulator (and device) I think because ...

My app works fine on browser but doesn't render the google map on emulator. This app is based on an exisiting app that already has a google map working fine on emulator (and device) I think because ...

  1. google maps working offline
  2. google maps working out distance
  3. google maps working slow
  4. google maps working principle
  5. google maps working without data
  6. google maps working
  7. google maps working without internet
  8. google maps working in china
  9. google maps working in airplane mode
  10. google maps not working
  11. google maps not working on iphone
  12. google maps not working android
  13. google maps not working properly
  14. google maps stopped working
  15. google maps not working on iphone 6
  16. google maps not working 2019
  17. google maps not working in chrome
  18. google maps not working on pc
  19. google maps isn't working
  20. google maps not working 2018

I'm new to JS. I'm studying the following code and I'm wondering what the word callback stands for, what does it? function(fileID, callback) { var request = $.ajax({ url: url + "wishlist/" + ...

I'm new to JS. I'm studying the following code and I'm wondering what the word callback stands for, what does it? function(fileID, callback) { var request = $.ajax({ url: url + "wishlist/" + ...

  1. what does callback mean
  2. what does callback mean in theatre
  3. what does callback mean in javascript
  4. what does callback function do
  5. what does callback mean in theater
  6. what does callback function mean
  7. what does callback number mean
  8. what does callback mean in programming
  9. what does callback mean in python
  10. what does callback date mean
  11. what does callback method mean
  12. what does callback mean on iphone
  13. what does callback return
  14. what does callback mean in c++
  15. what does callback mean in java
  16. what does callback mean in matlab
  17. what does callback status mean
  18. what does callback mean in php
  19. what does callback mean in jquery
  20. what does callback mean in history

I'm trying to build a prototype/ proof of concept that builds a website from markdown files hosted on Google Drive. I've had a look at the Google Drive API, but cant seem to find a way to read a file ...

I'm trying to build a prototype/ proof of concept that builds a website from markdown files hosted on Google Drive. I've had a look at the Google Drive API, but cant seem to find a way to read a file ...