BookmarkSubscribeRSS Feed
zhangrachel0118
Calcite | Level 5

Create the np_sort table that contains data for national parks. You want the data sorted by regional code and decreasing numbers of daily visitors. If necessary,start SAS before you begin.

Reminder: If you restarted your SAS session, you must open and submit the libname.sas program created in Activity 2.04 to access your course files.

  1. Open p103p08.sas from the practices folder.

  2. Modify the PROC SORT step to read pg1.np_summary and create a temporary, sorted table named np_sort.

  3. Add a BY statement to order the data by Reg and descending DayVisits values.

  4. Add a WHERE statement to select Type equal to NP.

  5. Submit the program and view the output data.

How many rows are in the np_sort table?

 

I cannot get the right answer for this question, and I am not sure if I am incorrect with the activity 2.04 or the coding for np_sort, and the error said that File WORK.NP_SUMMARY.DATA does not exist and Library PG1 does not exist.

2 REPLIES 2
Tom
Super User Tom
Super User

Read the REMINDER in what you just posted.

Did you run the libname.sas program?  Did it work?  If so it should have created the PG1 libref where you could find the input dataset.

Cynthia_sas
SAS Super FREQ
Hi:
I just posted some examples of how to construct the LIBNAME statement in your other post asking about the LIBNAME statement activity.
Cynthia

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 550 views
  • 0 likes
  • 3 in conversation