[DDI-users] How to model a value with unit

Wendy Thomas wlt at pop.umn.edu
Sat Feb 12 11:37:00 EST 2011


My,

Easiest to explain with examples:


Variable = Gender
    1 = Male
    2 = Female

Make a category scheme with the following categories
    CategoryA = Male
    CategoryB = Female

Make a code scheme where
    value = 1  category reference = CategoryA
    value = 2  category reference = CategoryB

Variable = Time in seconds

    NumericRepresentation with or without a valid range and the attribute 
measurementUnit="seconds"


Variable = Age in days

    NumericRepresentation with or without a valid range and the attribute 
measurementUnit="days"


I think your confusion may be in looking first at NCubes. These are 
aggregations and normally data that was collected as a Numeric is 
collapsed to groups such as age cohorts or specified ranges. In the case 
of a variable used as an NCube dimension the values of the variable 
provide the intercept point along the vector of that dimension, thereby 
providing part of its coordinate address. The content of the data file 
will be the value of the cell which falls at the given coordinate point. 
In addition the measurement unit in an NCube needs to be captured as a 
separate variable type because the same cube could be a count of persons, 
a percent, a ranking, a count of adults, etc. For example the variable 
describing the dimension of gender could be the gender of cats, dogs, 
people, etc. The NCube describes the measure type of a specific cell. So a 
variable expressing a measure of a count of cats might be

Variable = count of cats
    Numeric representation @measurementUnit="cats" 
aggregationMethod="count"

In a microdata variable the variable describes the value as found in the 
data set. In the above examples (if expressed for a case where the gender 
is female the time in seconds is 45 and the age in days is 92 a data 
record in a comma delimited file would look as follows

2,45,92

DDI has a number of different representation types:

Numeric - means the content can be analysed as a number
Text - content should be treated as character
Code - the content is a key to a specified label
DateTime - the content expresses a date or time and describes the format 
in which this is captured. The content is to be analysed as an expression 
of date or time rather than of a number.


Wendy



On Fri, 11 Feb 2011, My Coyne wrote:

> Hi,
>
> I would like to model a value that has unit, for example time {value = 
> 2, unit = second} or timve {value = 2, unit = years}.  Or age {value=1, 
> unit=day} etc.
>
> I was thinking of:
>
> 1. create a CategoryScheme
>         category value
>         category unit
> 2. Create a CodeScheme
>         code for second (=1) makes reference to category unit
>         code for minute (=2) makes reference to category unit
>         code for hour (=3) makes reference to category unit
>          ....
>          ....
>
>
> Is this an acceptable way to model a value with unit?  Please help with any idea or better way to do this.  Thank you
>
>
>
>
>
> _______________________________________________
> DDI-users mailing list
> DDI-users at icpsr.umich.edu
> http://www.icpsr.umich.edu/mailman/listinfo/ddi-users
>

Wendy L. Thomas                          Phone: +1 612.624.4389
Data Access Core Director		 Fax:   +1 612.626.8375
Minnesota Population Center              Email: wlt at pop.umn.edu
University of Minnesota
50 Willey Hall
225 19th Avenue South
Minneapolis, MN 55455


More information about the DDI-users mailing list