Question

Write a SAS program to import the tips.xls data. Name the resulting SAS dataset "tips" and...

Write a SAS program to import the tips.xls data. Name the resulting SAS dataset "tips" and store it in the temporary work library.

Examine the table (dataset) properties and then specify the informat of the variable DELIVERY.

Homework Answers

Answer #1

Sol:

proc import in sas is used to import a excel file.

datafile= tells SAS where to find the Excel file that you want to import

out=work.tips tells sas to create a dataset named tips stored in work library

dbms=xls tells sas the excel format file to read

replace is used to overwrite the tips dataset if it exists already

sheet="sheet1" tells SAS to import data from sheet1

getnames="yes"tells SAS to use the first row of data as variable names.

Write a SAS program to import the tips.xls data. Name the resulting SAS dataset "tips" and store it in the temporary work library.

SAS Code is:

proc import datafile="C:\tips.xls" out=work.tips

dbms=xls

replace;

sheet="sheet1";

getnames=yes;

run:

Examine the table (dataset) properties

SAS Code is

Proc contents data=work.tips;

run:

and then specify the informat of the variable DELIVERY.

SAS Code is

proc format

library=work.formats fmtlib;

select DELIVERY.;

run;

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
Write a program using K-Means and Expectation Maximization clustering for the given dataset. Use R language...
Write a program using K-Means and Expectation Maximization clustering for the given dataset. Use R language to write the code. Package Name: cluster.datasets install.packages("cluster.datasets") library(cluster.datasets) data(paste your data set name) your dataset name data(mammal.dentition) K-Means Clustering Find optimal number of clusters using Elbow Method and then Apply K-Means clustering. Finally do visualization for K-Means Clustering Expectation Maximization Clustering Q1: Apply Expectation Maximization Q2: Visualization for Expectation Maximization https://www.rdocumentation.org/packages/cluster.datasets/versions/1.0-1/topics/mammal.dentition I have done the K-means part do the second one
Subject Name: Data Management for Analytics Software used: SAS Choose the best single option. Q10. Consider...
Subject Name: Data Management for Analytics Software used: SAS Choose the best single option. Q10. Consider a categorical variable LOCATION with 10 levels: “location1”- “location10”. In order to create a new numeric variable which has only the numeric value extracted from each level name, which of the following SAS code will work? a. location_num = input(substr(location,2,2),2.); b. location_num = substr(location,2,2); c. location_num = substr(location,9,2); d. location_num = input(substr(location,9,1),1.); e. location_num = input(substr(location,9,2),2.);
Fix the error and execute the program again in sas. DATA height; *** This is an...
Fix the error and execute the program again in sas. DATA height; *** This is an example of column input; INPUT name $ 1-7 sex $ 10 age 12-13 height 15-18 weight 20-24 ** the following 2 statements are "sum statements" look at output to see how they work; count+1; totalwt+weight; CARDS; john m 12 59.0 99.5 james m 12 57.3 83.0 alfred m 14 69.0 112.5 william m 15 66.5 112.0 jeffrey m 13 62.5 84.0 mary f 15...
Write a program that does the following in C++ 1 ) Write the following store data...
Write a program that does the following in C++ 1 ) Write the following store data to a file (should be in main) DC Tourism Expenses 100.20 Revenue 200.50 Maryland Tourism Expenses 150.33 Revenue 210.33 Virginia Tourism Expenses 140.00 Revenue 230.00 2 ) Print the following heading: (should be in heading function) Store name | Profit [Note: use setw to make sure all your columns line up properly] 3 ) Read the store data for one store (should be in...
Write a 4-6 sentence summary explaining how you can use STL templates to create real world...
Write a 4-6 sentence summary explaining how you can use STL templates to create real world applications. In your summary, provide an example of a software project that you can create using STL templates and provide a brief explanation of the STL templates you will use to create this project. After that you will implement the software project you described . Your application must be a unique project and must incorporate the use of an STL container and/or iterator and...
Write a program that reads in a line consisting of a student’s name, Social Security number,...
Write a program that reads in a line consisting of a student’s name, Social Security number, user ID, and password. The program outputs the string in which all the digits of the Social Security number and all the characters in the password are replaced by x. (The Social Security number is in the form 000-00-0000, and the user ID and the password do not contain any spaces.) Your program should not use the operator [] to access a string element....
You will write a program that loops until the user selects 0 to exit. In the...
You will write a program that loops until the user selects 0 to exit. In the loop the user interactively selects a menu choice to compress or decompress a file. There are three menu options: Option 0: allows the user to exit the program. Option 1: allows the user to compress the specified input file and store the result in an output file. Option 2: allows the user to decompress the specified input file and store the result in an...
Write a Java program that Reads baseball data in from a comma delimited file. Each line...
Write a Java program that Reads baseball data in from a comma delimited file. Each line of the file contains a name followed by a list of symbols indicating the result of each at bat: 1 for single, 2 for double, 3 for triple, 4 for home run, o for out, w for walk, s for sacrifice Statistics are computed and printed for each player. EXTRA CREDIT (+10 points); compute each player's slugging percentage https://www.wikihow.com/Calculate-Slugging-Percentage Be sure to avoid a...
Please read the article and answear about questions. Determining the Value of the Business After you...
Please read the article and answear about questions. Determining the Value of the Business After you have completed a thorough and exacting investigation, you need to analyze all the infor- mation you have gathered. This is the time to consult with your business, financial, and legal advis- ers to arrive at an estimate of the value of the business. Outside advisers are impartial and are more likely to see the bad things about the business than are you. You should...