For a lot of application you need a barometer-trend;
usually last 3 hours ( because of significant
change ). I couldn't find those data in Meteohub.
Somebody knows how to solve that problem ?
Barotrend
Moderator: Mattk
Re:Barotrend
If you know a little PHP you can extract it from the all_sensors.txt data file -- there's a variable called seqhour1_thb0_sealevel_hpa that contains a snapshot of the barometric pressure every hour for the past 26 hours, separated by the underscore (_) character. The first measure is nearly-current data (within a few minutes, and thus nearly identical to actual_thb0_sealevel_hpa), so the fourth measure is three hours ago.
Parse those two out of the string, subtract them from one another, and you can determine three-hour trend.
As discussed in other posts on the forum, the VP2 interprets three-hour trends like this:
"Rising rapidly" is a net change of 2.0 hPa or greater.
"Rising slowly" is a change of between 0.7 to 2.0 hPa
"Steady" is a change of between -0.7 to 0.7 hPa.
"Falling slowly" is a change of -0.7 to -2.0 hPa.
"Falling rapidly" is a change of greater than -2.0 hPa.
I can provide some basic code if this is something you want to try implementing on your own website.
There are also two recently-added variables called last60m_thb0_press_trend and last24h_thb0_press_trend which return a '1' for rising, '0' for steady, and '-1' for falling, but they only cover either the past hour or past day, and still require some basic parsing to turn into a text string on a webpage. (There's also a hour1_thb0_press_trend, but it's less useful since the time-period it covers changes since it resets at the top of each hour.)
Parse those two out of the string, subtract them from one another, and you can determine three-hour trend.
As discussed in other posts on the forum, the VP2 interprets three-hour trends like this:
"Rising rapidly" is a net change of 2.0 hPa or greater.
"Rising slowly" is a change of between 0.7 to 2.0 hPa
"Steady" is a change of between -0.7 to 0.7 hPa.
"Falling slowly" is a change of -0.7 to -2.0 hPa.
"Falling rapidly" is a change of greater than -2.0 hPa.
I can provide some basic code if this is something you want to try implementing on your own website.
There are also two recently-added variables called last60m_thb0_press_trend and last24h_thb0_press_trend which return a '1' for rising, '0' for steady, and '-1' for falling, but they only cover either the past hour or past day, and still require some basic parsing to turn into a text string on a webpage. (There's also a hour1_thb0_press_trend, but it's less useful since the time-period it covers changes since it resets at the top of each hour.)
Re:Barotrend
In my all_sensors.txt i cannot find a variable
seqhourX_...
And also the variables ..._press_trend don't exist.
My Meteohub - Version is 2.6.
seqhourX_...
And also the variables ..._press_trend don't exist.
My Meteohub - Version is 2.6.
-
- Platinum Boarder
- Posts: 873
- Joined: Fri Jan 25, 2008 6:27 pm
- Location: Isle of Skye, Scotland
Re:Barotrend
Which sub version?bvatter wrote:My Meteohub - Version is 2.6.
IIRC the trends were only added in v2.6f (and may possibly have had additional tweaks since then, too).
Re:Barotrend
I now installed v2.8b. In the all_sensors there are no seqhour_ items. How to 3-hours-Barotrend.
Re:Barotrend
Written to soon; found the seqhours !!bvatter wrote:I now installed v2.8b. In the all_sensors there are no seqhour_ items. How to 3-hours-Barotrend.