Watchmaker Wiki

The ultimate watch maker for Android Wear!

User Tools

Site Tools


tips:feelslike

Adding a "Feels Like" Temperature

A “Feels Like” or “Apparent Temperature” can mean many different things, but typically, it's Actual Temperature, modified by Wind Chill or Heatindex, as appropriate. Okay, so why do we have separate Wind Chill and Heatindex pages then? Why not just have this one page?

Quite simply, the formulas for Wind Chill and Heatindex are already so mind-boggling long that having one super-mind-boggling formula that includes everything would be overwhelming, and probably more characters than the WatchMaker text field will allow. So, this page will show you how to get the same effect.

Examples

Wind Chill Object Opacity

 {wt}<80 and 100 or {wh}<40 and 100 or 0

Heatindex Object Opacity

 {wt}<80 and 0 or {wh}<40 and 0 or 100

Explanation

As stated in the intro, the Wind Chill and Heatindex formulas are very complex. Adding them together, along with extra conditionals to determine which to show, would result in such a lengthy formula that it would almost certainly be too many characters for the text field. Even if it does manage to squeeze in, it'd be a headache to deal with.

A simpler method is to create two separate text objects, one following the examples shown on the Wind Chill page, and one following the examples shown on the Heatindex page. Once the two text objects are created, make sure that the following parameters (if used) are identical between them:

  1. Position X
  2. Position Y
  3. Gyro Effect
  4. Text Size
  5. Rotation
  6. Skew X
  7. Skew Y
  8. Font
  9. Alignment
  10. Transform
  11. Display

Then, simply edit the Opacity field of the two objects with the applicable example. What this does is create the appearance of a single text object. The Opposing opacity values ensure that the two objects will never both show at the same time. If there is a HeatIndex, then the HeatIndex text object will show. If not, then the Wind Chill text object will show. Yes, that means that the Wind Chill object will show when there is neither Heatindex nor Wind Chill, but that's okay, because at that point, the Wind Chill object displays Actual Temperature anyway, which is what we want.

Having said all that, let's go back to that lengthy list of fields that need to be identical. Notice color wasn't among them? It's fine to have them be different colors; say, Red for Heatindex and Blue for Wind Chill. Just keep in mind that Wind Chill will be shown even if there's currently neither modifier in play. If you elect to use different colors, you may want to conditionally change the colors of the Wind Chill object so that it's (running with our previous examples) blue when there's a wind chill and white when there isn't. This will prevent you from having to create a third text object just to keep your color scheme. In this case, the formula would be placed under the Tint section of the text object, and would look something like:

 {wt}>50 and 'FFFFFF' or {wws}<3.1 and 'FFFFFF' or '0000FF' 
tips/feelslike.txt · Last modified: 2015/01/27 20:58 by jt3