cloudy cloudy

Author Topic: Saratoga Feels Like Temperature  (Read 185 times)

0 Members and 1 Guest are viewing this topic.

Offline mldenison

  • Posts: 306
  • OS/Browser:
  • Win 7/Srvr 2008R2
  • Chrome 75.0.3770.100
    • York, Pennsylvania USA Weather
Saratoga Feels Like Temperature
« on: July 11, 2019, 12:45:16 AM »
I just noticed on my Saratoga website that the Feels Like temperature is a little wonky.

This afternoon, the outdoor temperature was 81.5F and the Feels Like temperature showed 97F on my Saratoga site.  My Leuven site 86F.  As did my Davis console.

Where do I need to look in the code?

Thanks

« Last Edit: July 11, 2019, 11:14:25 AM by mldenison »

Offline saratogaWX

  • Global Moderator
  • Posts: 5,939
  • Ken True
  • Saratoga, CA, USA 37:16:28N, 122:01:23W - Elev: 374ft.
  • OS/Browser:
  • Win NT 10.0
  • Firefox 68.0
    • Saratoga Weather
Re: Saratoga Feels Like Temperature
« Reply #1 on: July 11, 2019, 02:37:45 PM »
With Weather-Display, the ajaxWDwx.js script uses humidex for the feels-like temperature
Code: [Select]
// FeelsLike
temp = clientraw[4]; // note.. temp in C
        if (temp <= 16.0 ) {
  feelslike = clientraw[44]; //use WindChill
} else if (temp >=27.0) {
  feelslike = clientraw[45]; //use Humidex
} else {
  feelslike = temp;   // use temperature
}
var feelslike  = Math.round(convertTemp(feelslike));
        set_ajax_obs("ajaxfeelslike",feelslike + uomTemp);

Likewise, in ajax-dashboard.php the $feelslike from testtags.php is used
Code: [Select]
                  <?php langtrans('Feels like'); ?>: <span class="ajax" id="ajaxfeelslike">
    <?php echo $feelslike $uomTemp?>
</span>
  <br/><br/>
                  <?php // $feelslike ?>
and the value is updated by the ajaxWDwx.js script when the AJAX starts running.
Ken True
Saratoga Weather
CWOP: CW1792
WeatherUnderground: KCASARAT1
Free weather website PHP scripts and WD website AJAX templates

Offline mldenison

  • Posts: 306
  • OS/Browser:
  • Win 7/Srvr 2008R2
  • Chrome 75.0.3770.100
    • York, Pennsylvania USA Weather
Re: Saratoga Feels Like Temperature
« Reply #2 on: July 11, 2019, 06:58:34 PM »
I've never understood Humidex.

For my weather camera image text, I had to use a formula to calculate Feels Like, which is close to the Davis Console Feels Like.

There's an Apparent temperature [130] that I've changed it to.  I'll follow it for a while to see what it shows.

I'm not sure why WD doesn't pass a Feels Like temperature in clientraw.

Thanks for the code location.

Mort

Offline Weerstation

  • Posts: 383
  • The Netherlands
  • OS/Browser:
  • Win NT 10.0
  • Mozilla compatible
Re: Saratoga Feels Like Temperature
« Reply #3 on: July 11, 2019, 09:06:12 PM »
Ken,

Some time ago I tried to edit the dashboard using $feelslikedp.
It did show feelslike temp with a decimal point but it did not autorefresh.
How would that code look in ajaxWDwx.js

TIA
Vantage Vue (Firmware 2.14 EU) - WeatherDisplay 10.37S build 99 - USB Weatherlink IP Data Logger

Windows 10 Home 64-bit - Acer Aspire Intel Core i5-8250U 1.6 GHz 8 Gb - Screen resolution 1920-1080

Offline saratogaWX

  • Global Moderator
  • Posts: 5,939
  • Ken True
  • Saratoga, CA, USA 37:16:28N, 122:01:23W - Elev: 374ft.
  • OS/Browser:
  • Win NT 10.0
  • Firefox 68.0
    • Saratoga Weather
Re: Saratoga Feels Like Temperature
« Reply #4 on: July 11, 2019, 11:57:48 PM »
Since clientraw.txt does not include a value for 'feelslike' (only for offsets [45]=Humidex and [112]=Heat Index) there is not data for an AJAX update to 'feelslike' from PHP.
Ken True
Saratoga Weather
CWOP: CW1792
WeatherUnderground: KCASARAT1
Free weather website PHP scripts and WD website AJAX templates

Offline niko

  • syzygy
  • Global Moderator
  • Posts: 28,126
  • Crystal Ball broken! Please post the URL.
  • Northern California, U.S.A.
  • OS/Browser:
  • Win 7/Srvr 2008R2
  • Chrome 75.0.3770.100
Re: Saratoga Feels Like Temperature
« Reply #5 on: July 12, 2019, 12:28:50 AM »
Unfortunately AFAIK there is no universally agreed definition of "Feels Like".

Clientraw also has [130]=Apparent Temp.

Offline mldenison

  • Posts: 306
  • OS/Browser:
  • Win 7/Srvr 2008R2
  • Chrome 75.0.3770.100
    • York, Pennsylvania USA Weather
Re: Saratoga Feels Like Temperature
« Reply #6 on: July 12, 2019, 12:39:20 AM »
Unfortunately AFAIK there is no universally agreed definition of "Feels Like".

Clientraw also has [130]=Apparent Temp.

That's what I'm using now instead of Humidex.  I'll see how it works out.  I've no idea on how it's calculated.