BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
kumarayas
Fluorite | Level 6

I have a SAS dataset where I see a letter "I" (Capital i) in numeric column. What does it mean?

I don't understand as it is a numeric variable and it should not contain this unless it means something else. I tried to add/subtract a number to it and it returned "." (null).

 

See below picture:

kumarayas_0-1585225800909.png

Here, "Factor" variable in 2nd row has letter "I" as Highlighted. The 3rd variable "db" is same as "factor" but with no format applied.

 

Table properties:

Compressed: CHAR

Encoding: wlatin1 Western (windows)

 

SAS version: 9.4m5

1 ACCEPTED SOLUTION

Accepted Solutions
FreelanceReinh
Jade | Level 19

Hi @kumarayas,

 

While programmers are free to use special missing values such as .I for arbitrary purposes, there are contexts in which .I has a special meaning: infinity. For example, the DIVIDE function and PROC TTEST produce this particular special missing value with the meaning "infinity" in certain situations (see code examples below). But even then it's still a missing value and recognized as such, e.g., by functions like MISSING, NMISS or CMISS.

/* Example 1 (Result: x=.I) */

data test;
x=divide(1,0);
run;

/* Example 2 (Result: UpperCLMean=.I) */

ods output conflimits=cl;
proc ttest data=sashelp.class sides=u;
var age;
run;

View solution in original post

6 REPLIES 6
Tom
Super User Tom
Super User

Most likely it is a special missing value.  In addition to the normal missing value, which is represented by a period, SAS allows 27 special missing values. They are represented in code by period followed by a letter or underscore. In listing/printing the period is not displayed.

 

Try something like this to see how many observations have .I for the DB variable.

proc print data=MYDATA;
  where db=.i ;
run;
FreelanceReinh
Jade | Level 19

Hi @kumarayas,

 

While programmers are free to use special missing values such as .I for arbitrary purposes, there are contexts in which .I has a special meaning: infinity. For example, the DIVIDE function and PROC TTEST produce this particular special missing value with the meaning "infinity" in certain situations (see code examples below). But even then it's still a missing value and recognized as such, e.g., by functions like MISSING, NMISS or CMISS.

/* Example 1 (Result: x=.I) */

data test;
x=divide(1,0);
run;

/* Example 2 (Result: UpperCLMean=.I) */

ods output conflimits=cl;
proc ttest data=sashelp.class sides=u;
var age;
run;
novinosrin
Tourmaline | Level 20

Thank you Sir @FreelanceReinh  for sharing. Always spot on and to the point. Kudos! Interestingly, I ran into something similar a week ago viz. special missings, though was able to figure the details after having read an amazing paper by @Quentin  on special missings for BY GROUP processing that I used for scoring. Cheers!

FreelanceReinh
Jade | Level 19

@novinosrin wrote:

... read an amazing paper by @Quentin  on special missings ...


I assume you mean "How to Represent Missing Data: Special Missing Values vs. 999999999." Indeed, this is really good and timeless. Thanks.

Quentin
Super User

Thanks for your kind words about my paper, @novinosrin  and @FreelanceReinh .  That was the first UG paper I ever wrote.  (I was too scared to present, so I did it as a poster for long-lost NESUG).  Always nice to know that a paper has been read!

The Boston Area SAS Users Group (BASUG) is hosting our in person SAS Blowout on Oct 18!
This full-day event in Cambridge, Mass features four presenters from SAS, presenting on a range of SAS 9 programming topics. Pre-registration by Oct 15 is required.
Full details and registration info at https://www.basug.org/events.

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 6 replies
  • 2722 views
  • 11 likes
  • 6 in conversation