Cloud Height Graphic v2.1

I have had this installed for a few months but one thing I have noticed is no matter if it is clear or not it always shows clouds but says clear. The clouds on the graphic are just at different levels. Also when it is raining or storming it never shows that it is raining or storming. Where would I need to look into first for this?

-Thanks

I thought I had this figured out and working correctly but I guess not. It is currently raining and the cloud graphic is showing scatter clouds. It doesn’t show as raining. If last week during our week long rain event it never showed as raining. Would someone care to share their settings if they have it working correctly?

-Thanks

Hi Rainer,
i’ve just installed your great script at http://www.meteocarmignano.it/
Weather Station of Carmignano (Po) - Tuscany, Italy
Please, could you insert my site into your download page?
Best regards,

Alessandro

Is it possible to use the actual metar reported cloud height vs the calculated method?
thanks and GREAT script

In the settings for the graphic you can choose to use Metar or WD method. You also set the Metar to use in the graphic settings.

Those settings are for the cloud conditions only, not the cloud height
thanks
John

They come hand in hand, it will report the cloud conditions as well as the height. What exactly is it you are trying to do?

Cloud conditions are only coming from Metar - cloudy, misty etc. The height is calculated either from WD or the Graphic code itself, but NOT pulled from Metar. I wanted to get the cloud height solely from Metar since i have an airport 4 miles from my house.

thanks

That can not be possible since it is ether one or the other. Like I said in the last post they come hand in hand. The cloud conditions and height are both reported from the same location. that you choose ether WD or a Metar. If you use WD it ising DP, Hum. pressure, temp, rain detected to calculate the sky conditions and cloud height. If you have a solar sensor you can use that with WD. If you pull it from the Metar you get the data from both from that metar.

Let me explain this further. If you had the advanced dashboard you could see what I am talking about. Since you don’t I will show you mine. You want your cloud height to be measured from the Metar and the conditions to be measure from WD. That is not possible because they go hand in hand. Look at my attached screen shot in the red boxes. The cloud graphic is showing the cloud condition and the height BOTH from the Metar. Now if you look at the bottom red box that is the Cloud height as calculated by WD. Notice the two numbers are not the same. So like I was saying it is ether or. You have to use one or the other, but you can use both because the cloud height and conditions go hand in hand.


Thanks for the reply. I actually want the conditions and cloud height solely from Metar. What Metar are you using for your site. Right now your site says Clear on the graphic. I agree the 2 readings on your graphic are different and the same thing was happening to me, which is why I too thought the height was from Metar. However when i looked at the actual Metar string from NOAA, my graphic sometimes was not even close. In fact it was never the same. The reason your screenshot shows a different reading for “Outside Now” compared to the Cloud graphic is “outside now” uses WD position 73 in clientraw.txt and the cloud graphic is using its own algorithm. This is why they are always so close.

I’d love for you to be right on this but i have never seen the actual Metar string match the cloud graphic height. I can’t find anywhere in the cloud-base.php code that pulls the height from Metar. I did find the following line that is put into ajaxWDwx.js for the cloud-base.php graphic - which is the algorithm:

cloudheight = Math.max(0,(temp-dewp)/0.00802)1.0 + stationAlt; // in meters
altitude = (useunits==“E”) ? Math.round(cloudheight
3.2808399) : Math.round(cloudheight);
above = (stationAlt>0)? ’ ASL’ : ’ AGL’;

Thoughts?

The cloud height is NOT coming from the metar. The cloud base script has the following to determine the cloud height:

// determine cloud height (in meters)
if ($useWDHeight && $cldhgtWD>0)
$cldhgt = $cldhgtWD;
else $cldhgt = max(0,($curtemp-$dewp)/0.00802)+$stationAltitude;

If you don’t use the Weather Display height, the script will calculate it.

That is a problem I have been having is the conditions are not always accurate from the Metar. When I showed you the screen shot I turned on the cloud band so you could see the difference in what the Metar and WD reports. You can have your Graphic and WD match. It is all in the settings.

// determine cloud height (in meters)
if ($useWDHeight && $cldhgtWD>0)
     $cldhgt = $cldhgtWD;
else $cldhgt = max(0,($curtemp-$dewp)/0.00802)+$stationAltitude;

That code above only comes into place if the settings are set like this.

$useWDHeight    = true; // always use the cloud height reported by WD (if you can trust it)

If you set it to false and have the use Metar set to true then it will use the Metar reports. But you have to have the three metars set to true.

Sorry, but you are incorrect. Height in Metars is only reported in hundreds of feet. It is never specific down to a foot. Metars are only updated once an hour.
The height in your graphic shows 7633 feet. That cannot be a metar reading when metars are only in hundreds of feet.

The cloud height in the graphic also changes more than once an hour.

The code always comes into play. If you don’t want to use the Weather Display calculation, then the script calculates the height.

The Metar is parsed only to get the cloud conditions. If the height is coming from the metar as you keep saying, please show me where in the script the height is getting parsed.

Mine is not showing anything because the conditions are clear, If you are looking the “Outside Now” section then yes that is coming from WD not the cloud graphic. Sky conditions along with your standard weather conditions are updated every 10 mins, cloud height with use of a Laser Ceilometer can refresh at the rate 30,60,120 secs and up to 180 with clear skys and can accurately measure up to 40,000 ft. It all depends on the method the metar is using, if it is using a Laser Ceilometer or a combination of UV sensors and current atmospheric conditions to measure height.

For example, this page parses data from METARS and is updated every 10-15 mins.

http://www.mesquitewx.com/weather.php?config=&forecast=zandh&pands=KHQZ&Submit=GO

My problem is it is not reporting sky conditions at all no matter what settings is used in the graphic. Which I believe it is because of lack of reporting conditions in the graphic. Keep in mind, just because the metar might not update as frequently as the graphic, doesn’t mean the graphic has to update. It can refresh up to every 3-5 secs but that doesn’t mean they height is going to change if the data is not current. It will just continue to read the current data until it receives new data. If you are using WD and use a Solar Sensor then it will take into account the formula

// determine cloud height (in meters)
if ($useWDHeight && $cldhgtWD>0)
     $cldhgt = $cldhgtWD;
else $cldhgt = max(0,($curtemp-$dewp)/0.00802)+$stationAltitude;

and the Solar Sensor and update it in realtime. Otherwise it will refresh, but the data won’t because you are not using the WD formula. If this is not the case then how am I getting two different cloud heights if they are both being calculated by WD?

I am seeing the ‘Clear’ sky condition on your graphic. But it is very difficult to see because it is in yellow text.

While looking at your page, the cloud height changed from 7838 to 7879 to 7674 to 7879 in less than two minutes.
The cloud height isn’t showing on the graphic itself, but if you mouse over the graphic, the height will be displayed.
Looking at the Metar for KHQZ, no cloud height is listed at all in the Metar. And since Metar heights are in multiples of 100 feet, the height is not coming from a metar.

As to why you get two different height readings, is one at sea level and the other above ground level? Are the differences generally in the same range? Is that range the same as your elevation?

Gmorning Rainer, you can add me to your list of cloud-base-graph users.
Just added it to my site. Looks good :thumbup:

http://www.weerstationGrave.nl

Hi guys, I love this script, but I was wondering if there’s any way to change the font color for the data. I use the beach background and you can’t read the conditions with the white font in the daytime. Thank you for any info! :slight_smile:

Anybody??

Hi, in the cloud-base.php you need to have a play in this section


// Add temperature text
if ($showTemp) {
   $sizT = $sizT+$sizS;
   imagestring ( $slate, 3, 3, 185, $txtT, $white);
}

// Add humidity text
if ($showHumidity) {
   $sizH = $sizH+$sizS;
   imagestring ( $slate, 3, 3+$sizT, 185, $txtH, $white);
}

// Add baro text
if ($showBaro) {
   imagestring ( $slate, 3, 3+$sizT+$sizH, 185, $txtB, $white);
}

// Add wind direction text
if ($showWindDir) {
   $txtD  = windDEGtoDIR($winddir);
   if (function_exists("langtransstr"))
      $txtD  = langtransstr($txtD);
   $sizD = strlen($txtD)*imagefontwidth(3);
   imagestring ( $slate, 3, 86-round($sizD/2), 174, $txtD, $white);
}

// Add windspeed text
$sizW = 0;
if ($showWindSpd) {
   $txtW = round($wind).$uomWind;
   $sizW = strlen($txtW)*imagefontwidth(2);
   imagestring ( $slate, 2, 84-round($sizW/2), 136, $txtW, $white);
}

// Add cloudheight text (if there's a cloud)
if ($imgClouds) {
   $txtC = round($cldhgt).' '.$uomAlt;
   $sizC = strlen($txtC)*imagefontwidth(2);
   $y = 170 - round($cldhgt/$scale["step"]);
   if ($y>124) $z = (round(60-$sizW)/2)-($sizC/2); else $z=32-($sizC/2);
   if ($z<0) { $font=1; $color=$yellow; $z=1; }
   else      { $font=2; $color=$white; }
   imagestring ( $slate, $font, 36+($z), $y, $txtC, $color);
	if ($showCloudTemp) {
		$txtC = round($cldtemp).'