SAS Base (59)

Given the contents of the raw data file TYPECOLOR.DAT:

—-+—-10—+—-20—+—-30
daisyyellow

The following SAS program is submitted:

data FLOWERS;
infile ‘TYPECOLOR.DAT’ truncover;
length
Type $ 5
Color $ 11;
input
Type $
Color $;
run;

What are the values of the variables Type and Color?

A. Type=daisy, Color=yellow
B. Type=daisy, Color=w
C. Type=daisy, Color=daisyyellow
D. Type=daisy, Color=

Check Answer
Answer: D

注解:The code neither specified where to read the value of each variable nor the delimiter. SAS will start to read value from left to right, using the default delimiter, space(‘ ‘). SAS reads the first value ‘daisyyellow’ and assigns it to variable ‘Type’. As the length of ‘Type’ is 5 which means it can only hold up to 5 characters, the value is truncated to ‘daisy’. Then SAS tries to read the second value for ‘Color’, but there is nothing left in the file. SAS simply sets the value to missing.

One of the proper way to read the file would be telling SAS the position of each variable:

data FLOWERS;
infile ‘TYPECOLOR.DAT’;
length
Type $ 5
Color $ 11;
input
Type $ 1-5
Color $ 6-11;
run;

Obs Type Color
1 daisy yellow

If you were not sure the length of the second variable, TRUNCOVER option would be handy. It enables you to read variable-length records when some records are shorter than the INPUT statement expects.

The following program will produce the identical result, except that the value of ‘Color’ could be any length from 0 to 15.

data FLOWERS;
infile ‘TYPECOLOR.DAT’ truncover;
length
Type $ 5
Color $ 11;
input
Type $ 1-5
Color $ 6-20;
run;

SAS Base (58)

The following program is submitted:

proc format;
value salfmt. 0 -< 50000 = ‘Less than 50K’ 50000 – high = ’50K or Greater’;

options fmterr nodate pageno=1;
title ‘Employee Report’;

proc print data=work.employees noobs;
var fullname salary hiredate;
format salary salfmt. hiredate date9.;
label fullname=’Name of Employee’ salary=’Annual Salary’ hiredate=’Date of Hire’;
run;

Why does the program fail?

A. The PAGENO option is invalid in the OPTIONS statement.
B. The RUN statement is missing after the FORMAT procedure.
C. The format name contains a period in the VALUE statement.
D. The LABEL option is missing from the PROC PRINT statement.

Check Answer
Answer: C

注解:When defining custom formats, the name of formats cannot end in a number or a period. The name, ‘salfmt.’, in VALUE statement is invalid. However, when you refer to the custom format, the ending period is necessary.

SAS Base (57)

Given the SAS data set WORK.ONE:

N BeginDate
1 09JAN201
2 12JAN201

The following SAS program is submitted:

data WORK.TWO;
set WORK.ONE;
Day=<_insert_code_>;
format BeginDate date9.;
run;

The data set WORK.TWO is created, where Day would be 1 for Sunday, 2 for Monday, 3 for Tuesday, … :

N BeginDate Day
1 09JAN2010 7
2 12JAN2010 3

Which expression successfully completed the program and creates the variable Day?

A. day(BeginDate)
B. weekday(BeginDate)
C. dayofweek(BeginDate)
D. getday(BeginDate,today())

Check Answer
Answer: B

注解:WEEKDAY function  returns an integer that corresponds to the day of the week, where 1=Sunday, 2=Monday, …, 7=Saturday, from a SAS date value. DAY function returns the day of the month. There is no function called DAYOFWEEK or GETDAY in SAS.

SAS Base (56)

The following output is created by the FREQUENCY procedure:

Frequency
Percent
Row Pct
Col Pct
Table of Region by Product
Region Product
Corn Cotton Oranges Total
East
2
22.22
50.00
50.00
1
11.11
25.00
33.33
1
11.11
25.00
50.00
4
44.44
South
2
22.22
40.00
50.00
2
22.22
40.00
66.67
1
11.11
20.00
50.00
5
55.56
Total
4
44.44
3
33.33
2
22.22
9
100.00

Which TABLES statement was used to completed the following program
that produced the output?

proc freq data=sales;
<_insert_code_>
run;

A. tables region product;
B. tables region,product;
C. tables region/product;
D. tables region*product;

Check Answer
Answer: D

注解:Comma and slash are invalid symbols in TABLES statement. Asterisk is used to create  multi-way tables. By adding an asterisk between two variables, SAS creates a two-way crosstabulation table. In option A, using a space between two variables, SAS will create two one-way frequency tables:

Region Frequency Percent Cumulative
Frequency
Cumulative
Percent
East 4 44.44 4 44.44
South 5 55.56 9 100.00
Product Frequency Percent Cumulative
Frequency
Cumulative
Percent
Corn 4 44.44 4 44.44
Cotton 3 33.33 7 77.78
Oranges 2 22.22 9 100.00

SAS Base (55)

The following SAS program is submitted:

data WORK.DATE_INFO;
X=”01Jan1960″D ;
run;

Variable X contains what value?

A. the numeric value 0
B. the character value “01Jan1960”
C. the date value 01011960
D. the code contains a syntax error and does not execute.

Check Answer
Answer: A

注解:Letter D is used to convert a normal date in DDMMMYY or DDMMMYYYY format to SAS date value. Check SAS Base (16) for details.

This question has another version. A space is placed between the closing quotation mark and letter D. This will cause a compile error and the answer would be D.

SAS Base (54)

Consider the following data step:

data WORK.TEST;
set SASHELP.CLASS(obs=5);
retain City ‘Beverly Hills’;
State=’California’;
run;

The computed variables City and State have their values assigned using two different methods, a RETAIN statement and an Assignment statement. Which statement regarding this program is true?

A. The RETAIN statement is fine, but the value of City will be truncated to 8 bytes as the LENGTH statement has been omitted.
B. Both the RETAIN and assignment statement are being used to initialize new variables and are equally efficient. Method used is a matter of programmer preference.
C. The assignment statement is fine, but the value of City will be truncated to 8 bytes as the LENGTH statement has been omitted.
D. City’s value will be assigned one time, State’s value 5 times.

Check Answer
Answer: D

注解:Both RETAIN statement and Assignment (=) statement can be used to assign values, but there are a few differences.

1. As RETAIN statement assigns the value at compile time, the code will be executed once and only once. Assignment statement, however, respecifies the value in every iteration.
2. SAS automatically sets variables that are assigned values by an assignment statement to missing before each iteration of the DATA step. On the contrary, RETAIN statement retains the value from one iteration to the next.

AS this program reads the first 5 observations (5 iterations) in CLASS data set,  the value of State is specified 5 times, and the variable is reset to missing when SAS begins to read the next observation. City is initialized as ‘Beverly Hills’ before DATA step and won’t be reset to missing.

SAS Base (53)

The following SAS program is submitted:

data WORK.TOTAL_SALARY;
retain Total;
set WORK.SALARY;
by Department;
if First.Department
then Total=0;
Total=sum(Total, Wagerate);
if Last.Total;
run;

What is the initial value of the variable Total?

A. 0
B. Missing
C. The value of the first observations Wagerate
D. Cannot be determined from the information given

Check Answer
Answer: B

注解:The second line of codes, retain Total, initializes the variable Total.  As it doesn’t specify an initial value, a missing value is assigned to the variable. Please also check SAS Base (32) for the details of RETAIN statement.

3), but as well and in particular the interpretative act of

buy canada goose jacket ecanadagoose.co.uk cheap Q. Rider Gabriel Hopkins canada goose factory outlet has wondered for years why the outdoor escalators going down to the Union Station platform seem to be reversed. “Why is it that, when you’re facing the escalators, the one you can travel on is to your left, rather than to your right?” he asked. buy canada goose jacket cheap

canada goose clearance This downgrade should be seen in this light. It is not a serious assessment of the nation’s canada goose outlet in usa fiscal condition. Center for Economic and Policy Research is an independent, nonpartisan think tank that was established to promote democratic debate on the most important economic canada goose outlet reviews and social issues that affect people lives. canada goose clearance

canadian goose jacket Furthermore, when it comes to criticizing the monopole of evidence based canada goose outlet black friday research in Natural Science, we canada goose outlet sale should consider that it is not this canada goose outlet jackets approach that “runs the risk of exalting biology into an ‘essential Being’ and a normative stasis ” (p. 3), but as well and in particular the interpretative act of clinicians and medecins which is worth having a deeper look in (as did Zimmermann 2016; Jurecic 2012; Hunter 1991). And, on canada goose jacket outlet the canada goose outlet uk opposite, it would canada goose outlet online uk be interesting to focus not only on the perspective of the “experts” but as well on the patients impact on co creating the array between health and sickness. canadian goose jacket

cheap Canada Goose FILE In this Oct. 26, 2015 file photo, fish swim over a patch of bleached coral in Hawaii’s Kaneohe Bay off the island of Oahu. Warmer water is canada goose black friday sale repeatedly causing mass global bleaching events to Earth’s fragile coral ree. Lambiyaan Si Judaiyaan captures the emotional journey of Sushant, KritiIt is sung by Arijit SinghJim Sarbh and Rajkummar Rao star in pivotal roles in RaabtaThe third song of Kriti Sanon and Sushant Singh Rajput’s upcoming film Raabta was unveiled today. Titled Lambiyaan Si Judaiyaan, the song features Kriti and Sushant’s separation. The song opens on Sushant, who learns that Kriti has chosen Jim Sarbh over official canada goose outlet him and later returns his ring. cheap Canada Goose

Canada Goose Parka Is fantastic to see British Gas investing in a base in Cornwall and bringing permanent jobs here, said Councillor Julian German, Cornwall canada goose outlet nyc Council portfolio holder for Economy and Culture. Is the first wave of what we hope will be around 40 jobs based canada goose outlet online in Cornwall, with around another 100 being either created or supported in the Green Deal and ECO assessment and installation sectors. British Gas has also committed to ensure canada goose outlet toronto factory that 60% of the Green Deal installations will be undertaken by local small and medium sized companies, setting the foundations for further stimulus to the local economy. Canada Goose Parka

canada goose store It has canada goose outlet the main commodity port, but it’s also been battered by successive wars and neglect for decades. Invasion in 2003, it fell under militia control. There was rampant corruption. The work of war photographers like Olive Edis would have been published in newspapers and exhibited in galleries. By 1918 the Ministry of Information would have tightly controlled how the war was represented at home. It is unlikely that Olive would have been chosen by the National War Museum (later renamed Imperial War Museums) for the canada goose outlet canada trip to the front if she had not agreed to abide by a number of conditions when taking her pictures. canada goose store

uk canada goose “We are keeping all upcoming events, including the General Election, under review. Our security measures and activities are constantly assessed to reflect where the threats exist and the canada goose outlet new york city level of threat we are canada goose outlet parka facing. We are unable to confirm the numbers of officers at particular locations or events for operational and security reasons.. uk canada goose

Canada Goose Outlet Life doesn’t have to be this hard. It’s easy for you to order food canada goose outlet shop online by simply visiting the restaurant’s website or Facebook page. It’s even easier to download their canada goose outlet uk sale free app and order through there. Ryan canada goose outlet store (Wis.), Senate Majority Leader Mitch McConnell (Ky.) and the various GOP presidential candidates should say, now, that they would never endorse or vote for him. Trump says about women but to avoid “piling on.” They should, moreover, “grab onto the best elements of [his] anti Washington populist agenda,” such as his tirades against globalization. Republicans canada goose outlet store should seek to be “authentic, independent, direct, firm,” like Mr. Canada Goose Outlet

Canada Goose sale US CHINA TRADE: Traders fear that the Trump administration is on the cusp of imposing tariffs of up to 25 percent on an additional $200 billion in Chinese imports, once a public comment period ends Thursday. Technological supremacy. Has applied new tariffs of up to 25 percent on nearly $85 billion worth of steel and aluminum and various Chinese products, mostly goods used in manufacturing. Canada Goose sale

canada goose uk shop Instead of wrapping paper I used a load of old Beano magazines which I stuck to the top using wallpaper paste. I also have a glass top panel which sits on top it looks really good! Thank you for the inspiration!Some very inexpensive easy ideas here. When people are just starting canada goose outlet store uk out in their own home or apartment ideas like this are just what they need because money is often tight. canada goose uk shop

buy canada goose jacket DevaCurl Decadence Conditioner (too expensive for how much I use, and not as much slip as some conditioners, not for my hair)4. As I Am Leave In Conditioner (love this, although, I use a LOT)5. SheaMoisture Coconut and Hibiscus Curl and Style Milk + Curl Enhancing Cream (I found the milk a bit too lightweight for my hair and preferred the thicker and heavier cream I was trying to use up the milk so I mixed them as I applied)6 buy canada goose jacket.

SAS Base (52)

Given the SAS data set WORK.EMP_NAME:

Name EmpID
Jill 1864
Jack 2121
Joan 4698
John 5463

Given the SAS data set WORK.EMP_DEPT:

EmpID Department
2121 Accounti
3567 Finance
4698 Marketin
5463 Accounti

The following program is submitted:

data WORK.ALL;
merge WORK.EMP_NAME(in=Emp_N)
WORK.EMP_DEPT(in=Emp_D);
by Empid;
if (Emp_N and not Emp_D) or (Emp_D and not Emp_N);
run;

How many observations are in data set WORK.ALL after submitting the program?

A. 1
B. 2
C. 3
D. 5

Check Answer
Answer: B

注解:The new data set WORK.ALL only contains observation which exits in EMP_Name but not in EMP_DEPT, or the other way around. WORK.ALL is:

Obs Name EmpID Department
1 Jill 1864
2 3567 Finance

For the details of MERGE statement and IN option, please check SAS Base (28).

But actually they did succeed

canada goose uk shop Looking back at the season as a whole so far, we have seen canada goose outlet uk 12 named storms, six hurricanes (Category 1+), and one major hurricane (Category 3+). Of the 12 named storms, half canada goose outlet kokemuksia were subtropical cyclones holding characteristics of both tropical and nontropical storms at some point in their Canada Goose Outlet lives, an unusually high percentage. In terms of Accumulated Cyclone Energy, or ACE, the season is at about 108 percent of canada goose outlet in chicago average for the date.. canada goose uk shop

canada goose uk black friday The fourth person finishes with the legs and feet. Open and check out your masterpiece!These were found at: Imagination SoupLet your half starved brood describe how hungry they are in this game, best played about half an hour before you make a pit canada goose outlet website legit stop for food. This version of the Packing for a Picnic game begins when you announce so hungry I could eat an aviator ( or The next player adds on with a B word. canada goose uk black friday

buy canada goose jacket cheap She has contributed to numerous other books, including Gardening for Dummies, The Encyclopedia of Organic Gardening, Seed to Seed and Gardener’s Home Companion. Barbara has also provided expertise to help develop the revolutionary Vegetable Garden Planner, which MOTHER EARTH NEWS premiered in 2010. She currently keeps a big, intensive food garden in Virginia that is terraced canada goose outlet toronto location into a west facing slope. buy canada goose jacket cheap

canada goose clearance sale The current weather conditions and infrastructure, the system would only provide sufficient potable water until the end of this year, so we need to find other sources, prior to the completion of the Scone to Murrurundi pipeline canada goose outlet sale in 2020. Corporation WaterNSW manages rivers and water supply systems, including 40 dams. Executive manager for canada goose outlet woodbury systems operations Adrian Langdon told the ABC that the long range forecast looked ahead three months and dry conditions were predicted to continue. canada goose clearance sale

Canada Goose sale Previous research on the stance where you stand tall with your legs spread and hands on your hips found that it can boost confidence in a stressful moment, which could lead to better performance. But new research shows canada goose outlet ottawa the technique may not enhance your success like scientists originally thought. While the pose may help you to feel powerful, it won’t actually lead to improved performance. Canada Goose sale

Canada Goose Outlet These served as a foundation for creative exploration, producing five contemporary fashion looks and one example garment. The five looks comprise a fashion collection that takes its inspiration from history. Colors, fabrics, silhouettes, and accessories all represent this theme. Canada Goose Outlet

canada goose black friday sale The kind that take over your life and leave you feeling guilty every time you “mess up.” Spoiler alert: These diets do not work. “And we don’t want to set people up for failure.”Dieters typically shed 5 to canada goose outlet store uk 10 percent of their starting weight within the first six months, according to researchers at UCLA. And there’s a good chance you’ve done canada goose outlet 2015 the same. canada goose black friday sale

Canada Goose online “Last night our lead story was the Medal of Honor awarded to Navy canada goose outlet authentic Lt. Michael Murphy, who was killed in Afghanistan trying canada goose outlet boston to save his unit. Lt. Fox News makes a habitit has imported the methods of George canada goose outlet phone number Orwell Newspeak where you can tell the people falsehoods and deceive themYou wouldn’t believe that in an open society, a democracy, these methods can succeed. But actually they did succeed, they succeeded in Germany where the Weimar Republic collapsed and you had the Nazi regime following. So this is a very, very dangerous way of deceiving people, and I would like people to be aware that they are canada goose uk site being deceivedBecause I saw it as a child, I immediately react that way; but people in America are innocent, they haven’t had that experience; they’re having the experience now, and I hope they wake up and realize they are being deceived.. Canada Goose online

cheap Canada Goose Despite coming from different walks of life, my acquaintances from all three groups share one thing in common: they https://www.canadagoosejacketca.ca understand the basic tenets of good business. They all love what they do, but they are still in the business of selling some kind of product, be it cabbage, paintings or insurance. They understand at a core level that in order to survive and continue doing what they are passionate about they must grow their customer base. cheap Canada Goose

canadian goose jacket While exact delivery fees are calculated based on a shopper home postcode, the Ikea Australia website explains: day home delivery is available for in store purchases to metro areas near all our canada goose parka uk stores. Delivery is charged at a flat rate, starting at $59, based on the delivery postcode, no matter how large your order. Regional delivery is also available. canadian goose jacket

canada goose coats You can make your own insect spray from harmless kitchen ingredients. Mix 1 tablespoon of dishwashing detergent with 1 cup of fresh cooking oil to make canada goose outlet online store review an effective, all natural bug killing concentrate that canada goose outlet winnipeg address can be mixed as needed. A solution of 4 teaspoons of concentrate diluted with 1 pint of water in a spray bottle is effective against many soft bodied insects, such as aphids, whiteflies and spider mites. canada goose coats

Canada Goose Jackets SPOKANE VALLEY, Wash. Firefighters were official canada goose outlet called to the scene at 2315 N. For a reported fire. But. I need a diet that’s easy to follow. Plenty of people turn to quickie diets because they have clear cut rules: Don’t eat carbs. The survey shows that in the past 12 months there were four recorded business failures in canada goose jacket outlet uk asset management.The challenge is not only with institutional investors; canada goose outlet ontario even retail customers looking to invest in a unit trust, a retirement annuity or a tax free savings account, for example, will normally go with the big brand names like Coronation or Allan Gray instead of seeking a black fund manager. This is largely owing to lack of access to markets and capital by black fund managers.Understandably, in the asset management space, institutions and retail investors want to invest in a reputable organisation that has a good track record in order for them to trust that the organisation will deliver. This acts as a double edged sword for most black asset managers Canada Goose Jackets.