Welcome to the Cumulus Support forum.

Latest Cumulus MX V4 release 4.4.2 (build 4085) - 12 March 2025

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

Legacy Cumulus 1 release 1.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

If you are posting a new Topic about an error or if you need help PLEASE read this first viewtopic.php?p=164080#p164080

Wind direction graph line intervals

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
freddie
Posts: 2870
Joined: Wed 08 Jun 2011 11:19 am
Weather Station: Davis Vantage Pro 2 + Ecowitt
Operating System: GNU/Linux Ubuntu 24.04 LXC
Location: Alcaston, Shropshire, UK
Contact:

Wind direction graph line intervals

Post by freddie »

I note that the wind direction graph horizontal line interval is set at 9 degrees. Is it possible to vary this to 5 or 10 degrees? It makes reading the average direction a bit easier.
Freddie
Image
User avatar
steve
Cumulus Author
Posts: 26672
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Wind direction graph line intervals

Post by steve »

They're at 45 degree intervals for me? Corresponding to the compass points.
Steve
User avatar
steve
Cumulus Author
Posts: 26672
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Wind direction graph line intervals

Post by steve »

Looking at your chart, it appears that Highcharts is drawing extra horizontal lines, 5 between each of the configured 45 degree lines, hence the 9 degree interval. I don't know what is causing it to do that on your chart, or how you might change it.
Steve
freddie
Posts: 2870
Joined: Wed 08 Jun 2011 11:19 am
Weather Station: Davis Vantage Pro 2 + Ecowitt
Operating System: GNU/Linux Ubuntu 24.04 LXC
Location: Alcaston, Shropshire, UK
Contact:

Re: Wind direction graph line intervals

Post by freddie »

Looking at your chart, it appears that Highcharts is drawing extra horizontal lines, 5 between each of the configured 45 degree lines, hence the 9 degree interval. I don't know what is causing it to do that on your chart, or how you might change it.
Okay thanks - it's always best to ask. I have no idea why my chart is different, I haven't altered anything (other than the ordering of the tabs) to make it so.
Freddie
Image
User avatar
steve
Cumulus Author
Posts: 26672
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Wind direction graph line intervals

Post by steve »

You could try setting a minorTickInterval - http://api.highcharts.com/highcharts#xA ... ckInterval

Looks like the default is a fifth of the tick interval, which explains what you're seeing. It must be deciding to do it on your chart based on your data.
Steve
User avatar
mcrossley
Posts: 14388
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Wind direction graph line intervals

Post by mcrossley »

Yep, you need to use the minorTickInterval as Steve suggested. I'd use a value of 15, if you use 10 then you will get lines 5 degrees either side of the cardinal points, and 5 is just too small.

Code: Select all

        yAxis: [{
                // left
                title: {text: 'Bearing'},
                opposite: false,
                min:0,
                max:360,
                tickInterval: 45,
                minorTickInterval: 15,
                labels: {
                    align: 'right',
                    x: -5,
                    formatter: function () {
                        return compassP(this.value);
                    }
                }                
            }, {
                // right
                linkedTo: 0,
                gridLineWidth: 0,
                opposite: true,
                title: {text: null},
                min:0,
                max:360,
                tickInterval: 45,
                minorTickInterval: 15,
  ....
freddie
Posts: 2870
Joined: Wed 08 Jun 2011 11:19 am
Weather Station: Davis Vantage Pro 2 + Ecowitt
Operating System: GNU/Linux Ubuntu 24.04 LXC
Location: Alcaston, Shropshire, UK
Contact:

Re: Wind direction graph line intervals

Post by freddie »

Thanks Mark. I report wind to the nearest 10 degrees, and I was aware of the fact that NE, SE, sw, etc., are a multiple of 5. I can live with the reduced spacing of the 5 interval, as the wind direction trace is painted on top.
Freddie
Image
freddie
Posts: 2870
Joined: Wed 08 Jun 2011 11:19 am
Weather Station: Davis Vantage Pro 2 + Ecowitt
Operating System: GNU/Linux Ubuntu 24.04 LXC
Location: Alcaston, Shropshire, UK
Contact:

Re: Wind direction graph line intervals

Post by freddie »

minorTickInterval set to 5 looks untidy, as the space between the grid lines is inconsistent. I changed tickInterval to 5, and altered the compassP() function such that it only returned a value under certain circumstances:

Code: Select all

var compassP = function (deg) {
        var a = ['N', 'NE', 'E', 'SE', 'S', 'SW', 'W', 'NW'];
        var bearing = deg % 45 == 0 ? a[Math.floor((deg + 22.5) / 45) % 8] : '';
        return bearing;
};
So I get labels every 45 degrees.

I've been experimenting with gridLineColor in order to emphasise the labelled lines right across the chart, but haven't had much luck as yet...
Freddie
Image
Locked