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 _n_?

Answer Posted / ravi

This is nothing but a implict variable created by SAS during
data processing. It gives the total number of records SAS
has iterated in a dataset. It is Available only for data
step and not for procs.

Eg. If we want to find every third record in a Dataset then
we can use the _n_ as follows
Data new-sas-data-set;
Set old;
if mod(_n_,3)= 1 then;
run;
Note: If we use a where clause to subset the _n_ will not
yield the required result.

Is This Answer Correct ?    13 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Difference between SAS STATA & SPSS?

1062


Explain why double trailing @@ is used in input statement?

1010


Mention how to limit decimal places for the variable using proc means?

1060


Are you involved in writing the inferential analysis plan? Tables specfications?

2507


What is factor analysis?

1079


How will you use the WHO Drug Dictionary for Reporting Clinical Trials?

2280


what is scheduling and how will u implement it. In scheduling 5 jobs r running if there is an error occured at 3rd job and how will u check and waht necessary steps will u take not to repeat the same mistake

2287


How to create an external dataset with sas code?

1073


i want for interview question & answer plz it need immediate send t my mail raviprakashmot@gmal.cm

2318


Explain what is the use of proc gplot?

1126


What would be the result of the following SAS function (given that 31 Dec, 2000 is Sunday)?

1101


Give e an example of..

2275


How would you code a merge that will write the matches of both to one data set, the non-matches from the left-most data?

1058


What is the use of stop statement?

1021


What are the limitations for memory allocation for SAS variables

1427