Welcome to the Cumulus Support forum.

Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024

Cumulus MX V4 beta test release 4.0.0 (build 4018) - 28 March 2024

Legacy Cumulus 1 release v1.9.4 (build 1099) - 28 November 2014 (a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)

Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki

Console Charts - Solar vs UV (cosmetic) [Fixed b3021]

Topics about the Beta trials up to Build 3043, the last build by Cumulus's founder Steve Loft. It was by this time way out of Beta but Steve wanted to keep it that way until he made a decision on his and Cumulus's future.

Moderator: mcrossley

Locked
User avatar
mcrossley
Posts: 12695
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Console Charts - Solar vs UV (cosmetic) [Fixed b3021]

Post by mcrossley »

Steve

The solar chart on the console does not plot solar and UV values together well. As the value ranges are so different 0-1200 vs. 0-10, the UV plot is just a squiggle along the y-axis. Ideally the UV needs it own y-axis (on the right?), don't know if that is possible with the package you are using?

Anyway it's a cosmetic thing, low priority.
Capture.PNG
You do not have the required permissions to view the files attached to this post.
Last edited by mcrossley on Wed 04 Mar 2015 6:52 pm, edited 1 time in total.
User avatar
mcrossley
Posts: 12695
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Console Charts - Solar vs UV (cosmetic)

Post by mcrossley »

Hmm, sort of, kinda works, not :roll: (you need to click on UV-I to hide it, then again to get it to show). Looks like there are not multiple y-axis options on line charts :(

Code: Select all

function createSolar() {
    nv.addGraph(function () {
        solarChart = nv.models.linePlusBarChart()
                //.useInteractiveGuideline(true)
                .x(function (d) {
                    return d[0];
                })
                .y(function (d) {
                    return d[1];
                })
                .color(d3.scale.category10().range())
                //.transitionDuration(300)
                .interpolate("monotone")
                .clipVoronoi(false);

        solarChart.margin({left: 60});

        solarChart.xAxis
                .tickFormat(function (d) {
                    return d3.time.format('%H:%M')(new Date(d));
                });

        solarChart.y1Axis
                .tickFormat(d3.format('.f'))
                .axisLabelDistance(30)
                .axisLabel('UV-I');

        solarChart.y2Axis
                .tickFormat(d3.format('f'))
                .axisLabelDistance(30)
                .axisLabel('Solar');

        solarChart.bars.forceY([0]);

        solarChart.xAxis.scale(d3.time.scale());
        solarChart.y1Axis.scale(d3.scale.linear().nice());
        solarChart.y2Axis.scale(d3.scale.linear().nice());
    });
}

function doSolar() {
    $('#loading').show();
    d3.json("api/graphdata/solardatad3.json", function (json) {
        d3.select('#chart1 svg').remove();

// kludge data
json[0].bar='true';

        d3.select('#chart1')
                .append('svg')
                .datum(json)
                .call(solarChart);

        nv.utils.windowResize(solarChart.update);

        $("#loading").fadeOut();

        return solarChart;
    });
}
Capture.PNG
You do not have the required permissions to view the files attached to this post.
User avatar
steve
Cumulus Author
Posts: 26702
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Console Charts - Solar vs UV (cosmetic)

Post by steve »

I hadn't noticed that as I don't have UV. It does appear to be possible with 'raw' d3.js but maybe not with nvd3.


As I understand it, charts with multiple (different) axes are frowned upon by data visualisation experts :roll:
Steve
bjamieson
Posts: 10
Joined: Thu 28 Nov 2013 7:15 pm
Weather Station: VP2
Operating System: Windows 7 Starter
Location: South Harbour

Re: Console Charts - Solar vs UV (cosmetic)

Post by bjamieson »

Interesting about the 'frowned upon' bit... For instance, I have a real requirement to be able to plot wind speed and amps against time.

My main power supply is a wind turbine, and it has been repaired and had bits replaced so often, that it's now sheer guess-work even for the 'professionals' who maintain it, as to how it performs.

I need to be able to plot and monitor what is happening in high winds so that adjustments can be made to tension springs, magnet separation distances etc etc. Bottom line is that being able to get as high a time-resolution windspeed plot (~2 sec) and compare that to an equivalent turbine amp plot will allow me to get adjustments made and verified, and not just by sticking my finger in the air and hoping for the best.

PS this is NOT having a go at you or Cumulus - just the notion that data visualisation seems to be getting dumbed down ? Maybe the nvd3 folks might look at adding the functionality ?

PPS - I LOVE the new graphs and the mouse-over tooltip data. I'm looking at adding mouse-wheel scroll to zoom the x-axis of my graphs from weeks <-> days <-> hours . Using D3 though...

All the best,

Brian
User avatar
steve
Cumulus Author
Posts: 26702
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Console Charts - Solar vs UV (cosmetic)

Post by steve »

I do agree with you that plotting different types of data on the same graph is often useful - pressure vs wind speed etc.
Steve
User avatar
mcrossley
Posts: 12695
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Console Charts - Solar vs UV (cosmetic) [Fixed b3021]

Post by mcrossley »

The UV plot scale issue is fixed with the switch to Highcharts in b3021. Thanks.
User avatar
Werk_AG
Posts: 198
Joined: Sun 13 Jan 2013 8:04 pm
Weather Station: WeatherDuino 4Pro
Operating System: Windows 7
Location: Cercal CDV - Portugal
Contact:

Re: Console Charts - Solar vs UV (cosmetic) [Fixed b3021]

Post by Werk_AG »

Thank you for the Highcharts in b3021.
User avatar
Werk_AG
Posts: 198
Joined: Sun 13 Jan 2013 8:04 pm
Weather Station: WeatherDuino 4Pro
Operating System: Windows 7
Location: Cercal CDV - Portugal
Contact:

Re: Console Charts - Solar vs UV (cosmetic) [Fixed b3021]

Post by Werk_AG »

It seems that in b3021, UV data is ploted as integers values only. Can this be changed to plot UV data with one decimal place?
User avatar
steve
Cumulus Author
Posts: 26702
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Console Charts - Solar vs UV (cosmetic) [Fixed b3021]

Post by steve »

It's actually using a decimal place, but it will be using a comma as I've missed the code to use invariant culture for UV - I'll fix that in the next build.
Steve
User avatar
Werk_AG
Posts: 198
Joined: Sun 13 Jan 2013 8:04 pm
Weather Station: WeatherDuino 4Pro
Operating System: Windows 7
Location: Cercal CDV - Portugal
Contact:

Re: Console Charts - Solar vs UV (cosmetic) [Fixed b3021]

Post by Werk_AG »

Thank you.
Locked