Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


What is LOGICAL VARIABLES in SAS.And how it can be used..Can
anyone support..???

Answers were Sorted based on User's Feedback



What is LOGICAL VARIABLES in SAS.And how it can be used..Can anyone support..???..

Answer / sangeeta

Fitst. and Last. varibles used in data step are called
Logical Variables.

Is This Answer Correct ?    26 Yes 3 No

What is LOGICAL VARIABLES in SAS.And how it can be used..Can anyone support..???..

Answer / nagaraju

Fitst. and Last. varibles are logical variables and returns
1 & 0 values.
These are mailnly used to give the first and last
occurances from the table.

ex: employee table having (1-100 employees) -- uses

if we give first.empid=1 then it gives only first employee
details
if we give first.empid=0 then it gives remaining employee
details except first one

in the same way

if we give last.empid=1 then it gives last employee details
if we give last.empid=0 then it gives remaining employee
details except last one
hope this is clear

Is This Answer Correct ?    22 Yes 3 No

What is LOGICAL VARIABLES in SAS.And how it can be used..Can anyone support..???..

Answer / xxx

Yes I agree with the above answers,
first.obs and last.obs are also specifies the occurrence of the data. If we mention like
first.obs=1 and last.obs=1;
it will eliminate the duplicates also.

Is This Answer Correct ?    7 Yes 0 No

Post New Answer

More SAS Interview Questions

how to import HTML files into SAS datasets?

3 Answers   HP,


For clinical entire study how many tables will create approx?

0 Answers   TCS,


libname deepak 'C:\SAS Files'; proc format; invalue convert 'A+' = 100 'A' = 96 'A-' = 92 'B+' = 88 'B' = 84 'B-' = 80 'C+' = 76 'C' = 72 'F' = 65; data deepak.grades; input ID $3. Grade convert.; *format Grade convert. ; datalines; 001 A- 002 B+ 003 F 004 C+ 005 A ; proc print data = deepak.grades; run; I get the following output Obs ID Grade 1 001 . 2 002 . 3 003 . 4 004 . 5 005 . I don’t understand why Grade shows up as a missing value. Everything seems fine, including ID $3. Now, in case I use ID : $3. Or use column input, I get the desired output. Kindly help Deepak

7 Answers  


how does sas handle missing values in a merge? : Sas programming

0 Answers  


Do you use PROC REPORT or PROC TABULATE? Which do you prefer? Explain.

3 Answers  


how does sas handle missing values in functions? : Sas programming

0 Answers  


how to rearrange the data as our wish by using dataset block?

4 Answers   Cognizant,


What is by-group processing?

0 Answers  


You need to perform an analysis on a massive dataset by groups, but are unable to sort the data due to memory constraint. How would you accomplish the task?

2 Answers  


What function CATX syntax does?

0 Answers  


what can you learn from the sas log when debugging? : Sas programming

0 Answers  


Under what circumstances would you code a SELECT construct instead of IF statements?

4 Answers  


Categories