SED navigation bar go to SED home page go to Dataplot home page go to NIST home page SED Home Page SED Staff SED Projects SED Products and Publications Search SED Pages
Dataplot Vol 2 Vol 1

OMIT

Name:
    OMIT (LET)
Type:
    Let Subcommand
Purpose:
    Given a group-id variable, create a tag variable based on a list of groups to omit.
Description:
    For some analyses, it may be necessary to omit some laboratories from the analysis. Although you can create an appropriate tag variable manually, the OMIT command can simplify that process.

    For example, if you have labs 1 to 10 and you want to omit labs 3 and 8 from the analysis, you can do something like the following

      LET XOMIT = DATA 3 8
      LET TAG = OMIT X XOMIT

    That is, this command will return a tag variable (TAG) based on the values of X. Values of X that match any value in XOMIT will be set to 0 and values of X that do not match any values in XOMIT will be set to 1.

Syntax:
    LET <tag> = OMIT <x> <xomit>             <SUBSET/EXCEPT/FOR qualification>
    where <x> is the group-id variable;
                <xomit> is a list of values to match against <x>;
                <tag> is a variable of the same length as <x> that will contain 0 where a match is found and 1 otherwise;
    and where the <SUBSET/EXCEPT/FOR qualification> is optional.
Examples:
    LET TAG = OMIT X XOMIT
Note:
    The KEEP command is similar. However, with the KEEP command you specify a list of lab id's to keep rather than to omit.
Default:
    None
Synonyms:
    None
Related Commands:
    KEEP = Create a tag variable based on a list of labs to keep.
    CODE = Generate a coded variable.
    COCODE = Generate a coded variable based on another variable.
    COCOPY = Generate a coded variable based on another variable.
Applications:
    Data Transformations
Implementation Date:
    2011/4
Program:
     
    skip 25
    read gear.dat y x
    set write decimals 4
    .
    let xomit = data 1 3 5 7 8 9
    let tag = omit x xomit
    print x tag y
        
    The following output is generated
    ---------------------------------------------
                  X            TAG              Y
    ---------------------------------------------
             1.0000         0.0000         1.0060
             1.0000         0.0000         0.9960
             1.0000         0.0000         0.9980
             1.0000         0.0000         1.0000
             1.0000         0.0000         0.9920
             1.0000         0.0000         0.9930
             1.0000         0.0000         1.0020
             1.0000         0.0000         0.9990
             1.0000         0.0000         0.9940
             1.0000         0.0000         1.0000
             2.0000         1.0000         0.9980
             2.0000         1.0000         1.0060
             2.0000         1.0000         1.0000
             2.0000         1.0000         1.0020
             2.0000         1.0000         0.9970
             2.0000         1.0000         0.9980
             2.0000         1.0000         0.9960
             2.0000         1.0000         1.0000
             2.0000         1.0000         1.0060
             2.0000         1.0000         0.9880
             3.0000         0.0000         0.9910
             3.0000         0.0000         0.9870
             3.0000         0.0000         0.9970
             3.0000         0.0000         0.9990
             3.0000         0.0000         0.9950
             3.0000         0.0000         0.9940
             3.0000         0.0000         1.0000
             3.0000         0.0000         0.9990
             3.0000         0.0000         0.9960
             3.0000         0.0000         0.9960
             4.0000         1.0000         1.0049
             4.0000         1.0000         1.0020
             4.0000         1.0000         0.9940
             4.0000         1.0000         1.0000
             4.0000         1.0000         0.9950
             4.0000         1.0000         0.9940
             4.0000         1.0000         0.9980
             4.0000         1.0000         0.9960
             4.0000         1.0000         1.0020
             4.0000         1.0000         0.9960
             5.0000         0.0000         0.9980
             5.0000         0.0000         0.9980
             5.0000         0.0000         0.9820
             5.0000         0.0000         0.9900
             5.0000         0.0000         1.0020
             5.0000         0.0000         0.9840
             5.0000         0.0000         0.9960
             5.0000         0.0000         0.9930
             5.0000         0.0000         0.9800
             5.0000         0.0000         0.9960
             6.0000         1.0000         1.0089
             6.0000         1.0000         1.0129
             6.0000         1.0000         1.0089
             6.0000         1.0000         0.9970
             6.0000         1.0000         0.9880
             6.0000         1.0000         1.0020
             6.0000         1.0000         0.9950
             6.0000         1.0000         0.9980
             6.0000         1.0000         0.9810
             6.0000         1.0000         0.9960
             7.0000         0.0000         0.9900
             7.0000         0.0000         1.0040
             7.0000         0.0000         0.9960
             7.0000         0.0000         1.0009
             7.0000         0.0000         0.9980
             7.0000         0.0000         1.0000
             7.0000         0.0000         1.0180
             7.0000         0.0000         1.0100
             7.0000         0.0000         0.9960
             7.0000         0.0000         1.0020
             8.0000         0.0000         0.9980
             8.0000         0.0000         1.0000
             8.0000         0.0000         1.0060
             8.0000         0.0000         1.0000
             8.0000         0.0000         1.0020
             8.0000         0.0000         0.9960
             8.0000         0.0000         0.9980
             8.0000         0.0000         0.9960
             8.0000         0.0000         1.0020
             8.0000         0.0000         1.0060
             9.0000         0.0000         1.0020
             9.0000         0.0000         0.9980
             9.0000         0.0000         0.9960
             9.0000         0.0000         0.9950
             9.0000         0.0000         0.9960
             9.0000         0.0000         1.0040
             9.0000         0.0000         1.0040
             9.0000         0.0000         0.9980
             9.0000         0.0000         0.9990
             9.0000         0.0000         0.9910
            10.0000         1.0000         0.9910
            10.0000         1.0000         0.9950
            10.0000         1.0000         0.9840
            10.0000         1.0000         0.9940
            10.0000         1.0000         0.9970
            10.0000         1.0000         0.9970
            10.0000         1.0000         0.9910
            10.0000         1.0000         0.9980
            10.0000         1.0000         1.0040
            10.0000         1.0000         0.9970
        

Date created: 06/23/2011
Last updated: 06/23/2011
Please email comments on this WWW page to alan.heckert@nist.gov.