SASCRUNCH TRAINING
  • Home
  • SASĀ® Certification Training
    • SAS Certified Specialist Exam Training Program
    • How to Prepare For SAS Certified Specialist Base Programming Exam
  • Online Courses
    • Practical SAS Training Course for Beginners
    • Proc SQL Course
    • SAS Project Training Course
    • Logistic Regression (Credit Scoring) Modeling using SAS
  • Articles
    • Get Started >
      • 18 Free Resources to Help You Learn SAS
      • SAS Tutorial
      • How to Install SAS Studio
      • How to Learn SAS Fast
    • Data Import >
      • Importing Excel Spreadsheet
      • Importing CSV Files
      • Importing Text Files
    • SAS Functions >
      • CAT, CATT, CATS, CATX Functions
      • If-Then-Else statement
      • TRIM Function
      • STRIP Function
      • YEAR, MONTH, DAY Functions
      • Compress Function
      • Do-Loop
      • SCAN Function
      • LIKE Operator
      • INDEX Function
    • Data Manipulations >
      • The Ultimate Guide to Proc SQL
      • Proc Datasets
      • Dictionary Tables
      • Dealing with Missing Values
      • Proc Compare
      • Proc Transpose
      • RETAIN Statement
      • SAS Formats
      • SAS Arrays
    • Statistical Analysis >
      • Proc Means
      • Proc Freq
      • Proc Tabulate
    • Machine Learning >
      • Predicting Fish Species Using K-nearest Neighbor in SAS
      • Classify Product Reviews on Amazon Using Naive Bayes Model in SAS
    • Informational Interviews >
      • How to get a Clinical Trial/Research job without experience
      • Senior Recruiter at a Fortune 500 Retail Company
      • Manager, Non-profit Health Services Research
      • HR Manager
      • Quantitative Analyst
  • Services
    • The Ultimate Job Search Automation Services
    • Statistical Consulting
    • SAS Project or Assignment Help
    • Data Import Services
    • Data Manipulation and Reporting Services
  • In-class Training
    • SAS Training for Job Seekers
  • Guest Lecture
  • Sample Resume
  • About us
  • Contact Us

SAS Project 1: Finding the Best Performing Stores

​
  • Level of difficulty: easy
  • Expected completion time: 1 hour

You have been hired as a SAS programmer and today is your first day at your job.

Unfortunately, today is also the deadline for a project and your boss needs your help processing some data before taking you out to lunch.
kpi.txt
File Size: 0 kb
File Type: txt
Download File

The data is saved in a text file, and you can download it from the link above.

The text file contains the KPI (Key Performance Indicator) data related to 10 retail stores.

The variables included are: 
  • Store: Store ID
  • Revenue: Revenue
  • Staff: Number of Staff 
  • Salary: Total Salary
  • Operation: Operation Cost 
  • Profit: Revenue - Total Salary - Operation Cost 
  • Complaint: Number of complaints
  • Turnover: Number of Employee Turnover

Your boss needs a SAS data set that contains only the stores with Revenue per Staff higher than $10,000.

You are expected to create the data set within one hour.

Step-by-step Instructions

​Do you need help to start the project? Check out the step-by-step instructions below for this project:

Step 1: Download and install the software
​
You need the software to start! The software can be downloaded from SAS for free. 


Step 2: Import the data into SAS

Once you have installed the software, you can start importing the data into SAS.

The data is stored in a text file and you can import the data using a procedure called Proc Import.

Check out our article on how to import a text file into SAS.

Note: if you aren't familiar with the software yet, check out the first two modules of our Practical SAS Training Course for Beginners. You will learn the basics of SAS within an hour (free).


Step 3: Identify the best performing stores
​

Once you have the data in SAS, you can use a simple IF-THEN statement to identify the stores with revenue per staff greater than 10000. 

Check out our article on how to use the IF-THEN-ELSE statement in SAS.


Step 4: Export the data to your shared folder

You can use a simple LIBNAME statement to save a SAS data set on your local drive.

Check out this module on how to access and save your SAS data set.

Relevant Resources
  • ​Software: Download SAS University Edition (free)
  • Article 1: ​How to install SAS Studio
  • Article 2: How to import text file into SAS
  • Article 3: IF-THEN-ELSE statement
  • Additional module 1: Create a Data Set
  • Additional module 2: Accessing Your Own Data Set
  • Additional module 3: ​Accessing Your Own Data Set II
  • Additional module 4: ​Saving a SAS Data Set
  • Course: Practical SAS Training Course for Beginners


FAQ
1. WHERE DO I GET THE SOFTWARE?

​You can download the SAS University Edition from SAS. The software is totally free. If you have a 64-bit machine, you can install the software on your computer at no cost.
2. How do i install SAS Studio?

The SAS University Edition runs on a virtual machine. You need to download both the virtual machine and SAS University Edition to run the software.

It is not as complex as you think. You can check out our step-by-step guide on how to download and install SAS University Edition on your computer.
​3. HOW DO I USE THE SOFTWARE? ARE THERE ANY TUTORIALS THAT TEACH HOW TO PROGRAM SAS?

If you are totally new to SAS, we'd recommend that you finish the first two modules of our Practical SAS Training Course for Beginners. 

You can learn the basics of SAS within one hour.
4. How do i import the data?

The data for this project is stored in a text file. You can use proc import to easily import the file.

Here's an article on how to import a text file into SAS. 
5. Can I create the data set without proc import?

Yes, you can create the data set with the stores data using Data Step instead of Proc Import.

You can learn how to create the data set properly in this module. 
6. How do I name the data set?

You can name the data set anything you want. However, the data set stores the KPI data. It would be appropriate to name it in an intuitive way (e.g. KPI, KPI_stores, etc.).
​
Please note that SAS data set names cannot:
  • Start with an integer
  • Contain spaces
  • Be longer than 32-characters
7. error: library does not exist

When you encounter this error, it means SAS cannot access the KPI text file on your computer.

More often than not, this is due to an incorrect path specified in your program.

Please note that SAS University Edition runs on a virtual machine. It is considered a separate operating system. You cannot directly access the data files on your local drive from the virtual machine.

If the path you specified in your program starts with a local drive (e.g. C:\SASUniversityEdition\myfolders), this is incorrect.

SAS University Edition can only access the files on your local drive through a shared folder. The path to the shared folder is: "/folders/myfolders". 

Review the tutorial and send us the code in the form below if you have any problems importing the file. We will give you a hand.
8. Where can I find the data set after i import the file?

Once you import the file, the data set should be created in the WORK library by default.​
Picture
9. How do I find stores with revenue per staff greater than $10,000?

A simple IF-statement can be used to find the stores that meet the selection criteria (i.e. revenue per staff greater than 10000). Check out our article on how to use the IF-THEN-ELSE statement in SAS if needed.
10. How do I export the data set to Windows?

In order to export a SAS data set, you must first create a SAS permanent library and save the data set in the permanent library. 

The modules below cover the topics needed to export a SAS data set:
  • Accessing Your Own Data Set
  • Accessing Your Own Data Set II
  • Saving a SAS Data Set
11. can i receive the solution?

Yes, you can! Simply submit your program below and you will receive the solution via email.

Submit your program and receive the solution!
Fill out my online form.
Copyright © 2012-2019 SASCrunch.com All rights reserved.
  • Home
  • SASĀ® Certification Training
    • SAS Certified Specialist Exam Training Program
    • How to Prepare For SAS Certified Specialist Base Programming Exam
  • Online Courses
    • Practical SAS Training Course for Beginners
    • Proc SQL Course
    • SAS Project Training Course
    • Logistic Regression (Credit Scoring) Modeling using SAS
  • Articles
    • Get Started >
      • 18 Free Resources to Help You Learn SAS
      • SAS Tutorial
      • How to Install SAS Studio
      • How to Learn SAS Fast
    • Data Import >
      • Importing Excel Spreadsheet
      • Importing CSV Files
      • Importing Text Files
    • SAS Functions >
      • CAT, CATT, CATS, CATX Functions
      • If-Then-Else statement
      • TRIM Function
      • STRIP Function
      • YEAR, MONTH, DAY Functions
      • Compress Function
      • Do-Loop
      • SCAN Function
      • LIKE Operator
      • INDEX Function
    • Data Manipulations >
      • The Ultimate Guide to Proc SQL
      • Proc Datasets
      • Dictionary Tables
      • Dealing with Missing Values
      • Proc Compare
      • Proc Transpose
      • RETAIN Statement
      • SAS Formats
      • SAS Arrays
    • Statistical Analysis >
      • Proc Means
      • Proc Freq
      • Proc Tabulate
    • Machine Learning >
      • Predicting Fish Species Using K-nearest Neighbor in SAS
      • Classify Product Reviews on Amazon Using Naive Bayes Model in SAS
    • Informational Interviews >
      • How to get a Clinical Trial/Research job without experience
      • Senior Recruiter at a Fortune 500 Retail Company
      • Manager, Non-profit Health Services Research
      • HR Manager
      • Quantitative Analyst
  • Services
    • The Ultimate Job Search Automation Services
    • Statistical Consulting
    • SAS Project or Assignment Help
    • Data Import Services
    • Data Manipulation and Reporting Services
  • In-class Training
    • SAS Training for Job Seekers
  • Guest Lecture
  • Sample Resume
  • About us
  • Contact Us