Welcome to the new home of the Cumulus Support forum.

Latest Cumulus release v1.9.4 (build 1099) - Nov 28 2014
Latest Cumulus MX release - v3.0.0 build 3044 7 December 2018. See the Wiki for download

Highcharts Graphs

Discussion and support for 3rd-party (non-Sandaysoft) tools for Cumulus
User avatar
Mapantz
Posts: 525
Joined: Sat 17 Dec 2011 11:55 am
Weather Station: Davis Vantage Pro2
Operating System: Windows 10 x64 - A beast.
Location: Wareham, Dorset - UK
Contact:

Re: Highcharts Graphs

Post by Mapantz » Sun 13 Aug 2017 7:58 pm

jlmr731 wrote:
Mapantz wrote:
Could you upload or link me to your .js for me, i'll have a look.

here is the script, as you can see its pretty much the default cumulusmx script only change i made was to add in a few more buttons on the temp graph and to a php file to get data from mysql

http://www.youngstownweather.com/js/mycumuluscharts.js
What's the graph page that uses that .js? I need to see what's happening, re the buttons disappearing..

Edit: Are you talking about the buttons being greyed out so you can't click them? If so, that would because you don't have enough data to show at those time/date ranges.
Image
Image

jlmr731
Posts: 118
Joined: Sat 27 Aug 2016 12:11 am
Weather Station: Davis vantage pro 2
Operating System: Debian
Location: Youngstown, Ohio
Contact:

Re: Highcharts Graphs

Post by jlmr731 » Sun 13 Aug 2017 9:06 pm

Mapantz wrote:
jlmr731 wrote:
Mapantz wrote:
Could you upload or link me to your .js for me, i'll have a look.

here is the script, as you can see its pretty much the default cumulusmx script only change i made was to add in a few more buttons on the temp graph and to a php file to get data from mysql

http://www.youngstownweather.com/js/mycumuluscharts.js
What's the graph page that uses that .js? I need to see what's happening, re the buttons disappearing..

Edit: Are you talking about the buttons being greyed out so you can't click them? If so, that would because you don't have enough data to show at those time/date ranges.
Sorry thought you wanted the js page
The main page would be http://www.youngstownweather.com/trends1.php
right now the selected: 0 is in there where you thought it should go
It will show the graph as expected but dont get the buttons to change range

User avatar
Mapantz
Posts: 525
Joined: Sat 17 Dec 2011 11:55 am
Weather Station: Davis Vantage Pro2
Operating System: Windows 10 x64 - A beast.
Location: Wareham, Dorset - UK
Contact:

Re: Highcharts Graphs

Post by Mapantz » Sun 13 Aug 2017 9:27 pm

Change the 0 to a 1, 2 or 3.

If you move the range selector along the bottom of the graph, the buttons appear. :D
Image
Image

jlmr731
Posts: 118
Joined: Sat 27 Aug 2016 12:11 am
Weather Station: Davis vantage pro 2
Operating System: Debian
Location: Youngstown, Ohio
Contact:

Re: Highcharts Graphs

Post by jlmr731 » Sun 13 Aug 2017 10:30 pm

Strange that they appear after movement, and changing the option does not help that.

Atleast im getting somewhere with it.
thanks

UncleBuck
Posts: 36
Joined: Sat 29 Dec 2012 10:27 pm
Weather Station: Davis VP2+
Operating System: MAC Mini - OSX El Capitan
Location: Victoria, Australia

Re: Highcharts Graphs

Post by UncleBuck » Thu 31 Aug 2017 12:45 am

Hi Mark,
I was wondering if you would be willing to share your table structure and trigger you use with the "comfort" graph?
I have it nearly all working now but that one graph is causing me grief as it appears to have changed quite significantly from the very first incantation of it.

Regards,
Colin.

User avatar
billy
Posts: 35
Joined: Mon 30 Nov 2015 10:54 am
Weather Station: Oregon WMR200
Operating System: RPi jessie
Location: Perth, Australia

Re: Highcharts Graphs

Post by billy » Sun 10 Sep 2017 1:44 pm

I can't find the right way of getting the source code of utils/realtimeLogSql.php for the recent graphs. I can run it from Mark's web site but can't download it as I have been able to do with all the php scripts for the historic graphs. Help would be appreciated.
Eric's Weather | Gooseberry Hill | Perth | Western Australia
Oregon WMR200 - RPi jessie
https://tillyspaws.com/weather/index.htm
https://tillyspaws.com/WAW/index.php
https://tillyspaws.com/pws/index.php

User avatar
billy
Posts: 35
Joined: Mon 30 Nov 2015 10:54 am
Weather Station: Oregon WMR200
Operating System: RPi jessie
Location: Perth, Australia

Re: Highcharts Graphs

Post by billy » Mon 11 Sep 2017 1:36 am

I'll answer my own question: http://weather.wilmslowastro.com/utils/ ... p?view=sce. It's the subtle variations in parameter settings you idiot. :groan:
Eric's Weather | Gooseberry Hill | Perth | Western Australia
Oregon WMR200 - RPi jessie
https://tillyspaws.com/weather/index.htm
https://tillyspaws.com/WAW/index.php
https://tillyspaws.com/pws/index.php

User avatar
billy
Posts: 35
Joined: Mon 30 Nov 2015 10:54 am
Weather Station: Oregon WMR200
Operating System: RPi jessie
Location: Perth, Australia

Re: Highcharts Graphs

Post by billy » Thu 11 Jan 2018 2:03 pm

Is there a simple answer to my dilemma? For some days, wind data (only) are missing because contact with the sensor was lost. There are a few occasions where this has occurred, with some instances of some consecutive days of missing data. The dayfile records are uploaded to a MySQL db and for the days where there is a complete absence of data, the wind values are zero. So, I would like suggestions on the relative benefits of these options:

1. Leave as is. Let sleeping dogs lie and accept that historic daily wind graphs, for example, have some dips down to zero.
2. Replace the zeros with interpolated values from either side of the missing periods. Would lead to some improvement in the look of the graph at least?
3. Get the data from nearby stations; although don't know whether this is possible. But it would/should improve the graphs appearances.
4. Change the wind variables to allow null values and set the zeros to null. And what might the flow-on effects of this be?

I'm sure others with much wiser and more experienced heads than mine, have thought this through. What do you suggest?
Eric's Weather | Gooseberry Hill | Perth | Western Australia
Oregon WMR200 - RPi jessie
https://tillyspaws.com/weather/index.htm
https://tillyspaws.com/WAW/index.php
https://tillyspaws.com/pws/index.php

uncle_bob
Posts: 476
Joined: Wed 17 Aug 2011 2:58 pm
Weather Station: WeatherDuino Pro2
Operating System: 2008
Location: Canberra

Re: Highcharts Graphs

Post by uncle_bob » Sun 06 May 2018 10:39 am

Hi Mark, or anyone else with an answer :)
I'm tying to set up the ImportCumulusFile.php script but it bombing out with the following.
Any ideas?

Running from web server
Script start: 06/05/18 - 12:34:38
Importing file: C:\Cumulus\data\dayfile.txt, To table: Dayfile ...
Connected to database OK.
Set MySQL TZ OK.
Processing dayfile...
Target table already exists.
Prepared SQL statement OK.
Inserting data...
Error: Failed to bind the SQL parameters!
Interested in building your own Weather Station? Maybe check out the WeatherDuino Pro Project Here
Conder, Canberra Weather
Image

User avatar
mcrossley
Posts: 5231
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2
Operating System: Stretch Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Highcharts Graphs

Post by mcrossley » Sun 06 May 2018 4:59 pm

Which version of the script?
Which version of the script created the database tables?

uncle_bob
Posts: 476
Joined: Wed 17 Aug 2011 2:58 pm
Weather Station: WeatherDuino Pro2
Operating System: 2008
Location: Canberra

Re: Highcharts Graphs

Post by uncle_bob » Sun 06 May 2018 10:04 pm

3.1 for both (it's a new installation, just have run the script more that once)

Would I see that if the path is wrong to the log file?
It's running on Xampp on Windows and Cumulus1 is on C:/Cumulus (
Interested in building your own Weather Station? Maybe check out the WeatherDuino Pro Project Here
Conder, Canberra Weather
Image

User avatar
mcrossley
Posts: 5231
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2
Operating System: Stretch Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Highcharts Graphs

Post by mcrossley » Mon 07 May 2018 9:08 am

Ah, how far back does your data go?

I suspect that you may be being caught by the fact that newer versions of Cumulus added extra data to the file. The script may be trying to import data to columns for which no data exists in the file (or at least the number of "empty" commas doesn't match the number of fields in the current version).

uncle_bob
Posts: 476
Joined: Wed 17 Aug 2011 2:58 pm
Weather Station: WeatherDuino Pro2
Operating System: 2008
Location: Canberra

Re: Highcharts Graphs

Post by uncle_bob » Mon 07 May 2018 10:20 am

Here's the first five lines from the dayfile.

Code: Select all

31/12/01,13.0,22,11:03,20.7,09:01,30.1,11:29,1010.7,11:24,1011.7,09:04,0.0,09:00,0.0,25.0,2.9,3.9,11:24,44,11:04,67,09:00,0.00,0.0,30.4,11:29,31.9,11:29,22.1,09:01,0.0,09:00,20.7,09:01,16.9,11:29,14.4,09:01,347,0.0,0.7,,,,
31/12/01,6.5,360,02:02,0.0,01:34,26.7,01:35,0.0,01:34,1013.0,08:02,0.0,01:34,0.0,22.0,6.5,6.5,02:02,0,01:34,63,08:02,0.00,0.0,27.0,01:35,27.9,01:35,0.0,01:34,0.0,01:35,0.0,01:34,16.9,01:34,7.3,02:02,359,0.0,1.1,,,,
31/12/01,6.5,360,11:33,21.0,09:00,24.7,11:37,1011.1,10:40,1011.7,09:57,0.0,09:00,0.0,22.6,0.0,0.5,11:37,69,11:33,82,09:00,0.00,0.0,24.7,11:37,27.8,11:37,23.6,09:03,0.0,09:00,21.0,09:00,18.9,11:37,17.6,09:03,8,0.0,0.5,,,,
01/01/02,25.9,135,15:15,21.9,09:02,30.8,13:02,1010.1,14:02,1012.7,09:02,0.0,00:00,0.0,26.7,72.5,7.8,15:15,34,13:02,61,09:02,0.00,0.0,29.9,13:02,31.8,13:02,23.2,09:02,0.0,00:00,21.9,09:02,15.1,12:02,10.7,15:15,132,8.4,0.0,0,00:00,0.0,00:00
17/08/11,27.0,67,21:48,0.0,03:47,10.4,00:26,943.7,04:14,948.2,21:51,18.0,00:59,62.2,8.1,30.7,27.0,21:48,89,00:56,92,05:33,0.00,0.0,20,05:47,21,05:47,-2.2,03:47,5.2,00:28,2.2,21:48,50.8,03:44,2,03:03,,,,,,,
So there's bad data right there as I never had a station in 2001

EDIT: So I deleted that bum data and tried again, no dice yet.
Interested in building your own Weather Station? Maybe check out the WeatherDuino Pro Project Here
Conder, Canberra Weather
Image

uncle_bob
Posts: 476
Joined: Wed 17 Aug 2011 2:58 pm
Weather Station: WeatherDuino Pro2
Operating System: 2008
Location: Canberra

Re: Highcharts Graphs

Post by uncle_bob » Mon 07 May 2018 10:43 am

Just to note that I tried a monthly and that worked!
Interested in building your own Weather Station? Maybe check out the WeatherDuino Pro Project Here
Conder, Canberra Weather
Image

User avatar
mcrossley
Posts: 5231
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2
Operating System: Stretch Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Highcharts Graphs

Post by mcrossley » Mon 07 May 2018 1:31 pm

OK, I'll use that data to try it later tonight.

If you fancy trying version 2.8 of the script, that does not use parameter binding, it isn't as fast for bulk uploads, but it may be interesting to see if that works, and if not the error may be more helpful.

Post Reply