[uf-discuss] Re: Currency + Unit of measurement (Was: Currency+Product)

Guillaume Lebleu gl at brixlogic.com
Fri Sep 29 15:38:41 PDT 2006


One little correction in the text below.

The following rules should be used:

   * "unit" is optional
   *  if "unit" is present, then "value" is optional, and if "value" not 
present, then it is assumed to be 1.

Guillaume

Guillaume Lebleu wrote:
> I don't think Lorenzo is talking of: *currency amount per 
> item/product* as your title and example imply (that, I agree, is a 
> non-starter)
>
> but of *currency amount per unit of measurement* (which is widely used 
> - see for instance: http://www.bloomberg.com/energy/, although not in 
> the context of a house/product/job in which case the unit is obvious).
>
> In "$25 per barrel" or in "25 ($/bbl)", I think you would agree that 
> knowing that the barrel is the unit of measurement is very 
> significant, and even though knowing that "$" means USD dollars, 
> overlooking that it is a price per barrel would lead to a big mistake.
>
> I think Lorenzo is furthermore suggesting that a currency is just 
> another unit. I agree conceptually that it is, but in practice, 
> standard bodies (that I know of) have traditionally separated currency 
> amounts from other measures. For instance, I took a look at the UNECE 
> recommended codes for units of measurement (reused by some industry 
> standards), available at: 
> http://www.unece.org/cefact/codesfortrade/codes_index.htm. 
> http://www.unece.org/cefact/recommendations/rec20/rec20.zip. They 
> indeed have the barrel (US) as a well-known unit, but as I mentioned 
> UNECE does not include currencies in their list of units of measurement.
>
> Which leads me to my updated code examples.
>
> <span class="price"><abbr class="currency" title="USD">$</abbv><span 
> class="value">25</span> <span class="unit" title="BLL">per 
> barrel</span></span>
>
> <span class="price"><span class="value">25</span> <abbr 
> class="currency" title="USD">$</abbv><abbr class="unit" 
> title="BLL">/bbl</abbr></span></span>
>
> <span class="price">On <abbr class="datetime" 
> title="1998-03-12T08:30:00-05:00">August 1</abbr>, the US Dollar still 
> stood at <span class="value">643 <abbr class="currency" 
> title="DEM">Marks</abbr></span> to the <span class="unit currency" 
> title="USD">Dollar</span>.</span>
>
> The following rules should be used:
>
>    * If "value" is not present, then value = 1.
>    * "unit" is optional
>
> By the way, I haven't found any measurement microformat on the wiki, 
> so maybe we could do the currency+measurement at the same time.
>
> Let me know what you think.
>
> Guillaume
> _______________________________________________
> microformats-discuss mailing list
> microformats-discuss at microformats.org
> http://microformats.org/mailman/listinfo/microformats-discuss
>
>


More information about the microformats-discuss mailing list