Shubham_Jethwa_Assignment 1

pdf

School

Seneca College *

*We aren’t endorsed by this school

Course

110

Subject

Business

Date

Feb 20, 2024

Type

pdf

Pages

9

Uploaded by SuperEnergyTarsier27

Report
/*ASSIGNMENT 1 Name- Shubham H. Jethwa Student ID- 160470191 */ * Q1. Load data from customer_banking_info_promo.xslx; libname mylib '/home/u63019012/BAN110_Assignment'; proc import datafile='/home/u63019012/BAN110_Assignment/customer_banking_info_promo.xlsx' out=mylib.customer_banking_info_promo dbms=xlsx replace; run; proc print data=mylib.customer_banking_info_promo (obs=5) noobs; run; *Q2. Examine the variable Customer ID. Check the type and format.; title"Question 2"; proc contents data=mylib.customer_banking_info_promo; run; *Q3. Column deletion/renaming; title "Question 3"; data mylib.customer_banking_info_promo; set mylib.customer_banking_info_promo; rename customer_id2=customer_id; drop duration; run; PROC PRINT data=mylib.customer_banking_info_promo(obs=5); run;
*Q4. Load data from customer_banking_info.csv; title "Question 4"; proc import datafile='/home/u63019012/BAN110_Assignment/customer_banking_info.csv' out = mylib.customer_banking_info dbms = csv replace ; run; proc print data=mylib.customer_banking_info (obs=5); run; *Q5. Renaming columns; title "Question 5"; proc contents data= mylib.customer_banking_info; run; data mylib.customer_banking_info; set mylib.customer_banking_info; rename customer_id1 = customer_id; run; proc print data = mylib.customer_banking_info(obs=5); run; *Q6. SAS data from customer_demographics.sas7bdat; title "Question 6"; proc print data = mylib.customer_demographics (obs = 5); run; proc contents data = mylib.customer_demographics; run;
*Q7. Convert from character to numeric; title "Question 7"; data customer_banking_info_promocv; set mylib.customer_banking_info_promo; num_customer_id = input (customer_id, 11.); drop customer_id; rename num_customer_id = customer_id; run; proc print data = customer_banking_info_promocv (obs = 5); run; proc contents data = customer_banking_info_promocv; run; *Q8. Data Merging; title "Question 8"; proc sort data = mylib.customer_banking_info; by customer_id; run; proc sort data = customer_banking_info_promocv; by customer_id; run; proc sort data = mylib.customer_demographics; by customer_id; run; data customer_all; merge customer_banking_info_promocv
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
Mylib.customer_banking_info Mylib.customer_demographics; by customer_id; run; proc print data = customer_all (obs=5); run;
2/12/23, 7:45 PM Results: Program 1 https://odamid-usw2-2.oda.sas.com/SASStudio/sasexec/submissions/450aba6a-1f38-4fca-a240-651d9011c536/results 1/5 customer_id2 contact day month duration campaign pdays previous poutcome y 122482 cellular 22 aug 229 2 -1 0 unknown no 119725 cellular 7 aug 125 2 -1 0 unknown no 103490 unknown 15 may 68 2 -1 0 unknown no 126218 cellular 19 nov 517 2 187 3 failure no 104835 unknown 20 may 165 2 -1 0 unknown no Question 2 The CONTENTS Procedure Data Set Name MYLIB.CUSTOMER_BANKING_INFO_PROMO Observations 10578 Member Type DATA Variables 10 Engine V9 Indexes 0 Created 02/12/2023 19:23:52 Observation Length 72 Last Modified 02/12/2023 19:23:52 Deleted Observations 0 Protection Compressed NO Data Set Type Sorted NO Label Data Representation SOLARIS_X86_64, LINUX_X86_64, ALPHA_TRU64, LINUX_IA64 Encoding utf-8 Unicode (UTF-8) Engine/Host Dependent Information Data Set Page Size 131072 Number of Data Set Pages 6 First Data Page 1 Max Obs per Page 1816 Obs in First Data Page 1773 Number of Data Set Repairs 0 Filename /home/u63019012/BAN110_Assignment/customer_banking_info_promo.sas7bdat Release Created 9.0401M7 Host Created Linux Inode Number 8327364044 Access Permission rw-r--r-- Owner Name u63019012 File Size 896KB File Size (bytes) 917504 Alphabetic List of Variables and Attributes # Variable Type Len Format Informat Label 6 campaign Num 8 BEST. campaign 2 contact Char 9 $9. $9. contact 1 customer_id2 Char 6 $6. $6. customer_id2 3 day Num 8 BEST. day 5 duration Num 8 BEST. duration 4 month Char 3 $3. $3. month 7 pdays Num 8 BEST. pdays 9 poutcome Char 7 $7. $7. poutcome 8 previous Num 8 BEST. previous 10 y Char 3 $3. $3. y Question 3 Obs customer_id contact day month campaign pdays previous poutcome y 1 122482 cellular 22 aug 2 -1 0 unknown no 2 119725 cellular 7 aug 2 -1 0 unknown no
2/12/23, 7:45 PM Results: Program 1 https://odamid-usw2-2.oda.sas.com/SASStudio/sasexec/submissions/450aba6a-1f38-4fca-a240-651d9011c536/results 2/5 Obs customer_id contact day month campaign pdays previous poutcome y 3 103490 unknown 15 may 2 -1 0 unknown no 4 126218 cellular 19 nov 2 187 3 failure no 5 104835 unknown 20 may 2 -1 0 unknown no Question 4 Obs customer_id1 default balance housing loan 1 122482 no 347 no no 2 119725 no 3462 no no 3 103490 no 157 yes no 4 126218 no 3689 yes no 5 104835 no 0 yes yes Question 5 The CONTENTS Procedure Data Set Name MYLIB.CUSTOMER_BANKING_INFO Observations 10578 Member Type DATA Variables 5 Engine V9 Indexes 0 Created 02/12/2023 19:23:53 Observation Length 32 Last Modified 02/12/2023 19:23:53 Deleted Observations 0 Protection Compressed NO Data Set Type Sorted NO Label Data Representation SOLARIS_X86_64, LINUX_X86_64, ALPHA_TRU64, LINUX_IA64 Encoding utf-8 Unicode (UTF-8) Engine/Host Dependent Information Data Set Page Size 131072 Number of Data Set Pages 3 First Data Page 1 Max Obs per Page 4078 Obs in First Data Page 4002 Number of Data Set Repairs 0 Filename /home/u63019012/BAN110_Assignment/customer_banking_info.sas7bdat Release Created 9.0401M7 Host Created Linux Inode Number 8327364043 Access Permission rw-r--r-- Owner Name u63019012 File Size 512KB File Size (bytes) 524288 Alphabetic List of Variables and Attributes # Variable Type Len Format Informat 3 balance Num 8 BEST12. BEST32. 1 customer_id1 Num 8 BEST12. BEST32. 2 default Char 3 $3. $3. 4 housing Char 3 $3. $3. 5 loan Char 3 $3. $3. Question 5
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
2/12/23, 7:45 PM Results: Program 1 https://odamid-usw2-2.oda.sas.com/SASStudio/sasexec/submissions/450aba6a-1f38-4fca-a240-651d9011c536/results 3/5 Obs customer_id default balance housing loan 1 122482 no 347 no no 2 119725 no 3462 no no 3 103490 no 157 yes no 4 126218 no 3689 yes no 5 104835 no 0 yes yes Question 6 Obs Education customer_id AGE marital JOB 1 secondary 100103 33 married entrepreneur 2 tertiary 100106 35 married management 3 primary 100118 57 married blue-collar 4 primary 100119 60 married retired 5 secondary 100121 28 married blue-collar Question 6 The CONTENTS Procedure Data Set Name MYLIB.CUSTOMER_DEMOGRAPHICS Observations 10578 Member Type DATA Variables 5 Engine V9 Indexes 0 Created 01/24/2019 12:27:12 Observation Length 48 Last Modified 01/24/2019 12:27:12 Deleted Observations 0 Protection Compressed NO Data Set Type Sorted YES Label Data Representation SOLARIS_X86_64, LINUX_X86_64, ALPHA_TRU64, LINUX_IA64 Encoding utf-8 Unicode (UTF-8) Engine/Host Dependent Information Data Set Page Size 65536 Number of Data Set Pages 8 First Data Page 1 Max Obs per Page 1360 Obs in First Data Page 1310 Number of Data Set Repairs 0 Filename /home/u63019012/BAN110_Assignment/customer_demographics.sas7bdat Release Created 9.0401M5 Host Created Linux Inode Number 8327364042 Access Permission rw-r--r-- Owner Name u63019012 File Size 576KB File Size (bytes) 589824 Alphabetic List of Variables and Attributes # Variable Type Len Format Label 3 AGE Num 8 F4. AGE 1 Education Char 9 $CHAR9. Education 5 JOB Char 14 $CHAR14. JOB 2 customer_id Num 8 4 marital Char 8 $CHAR8. marital Sort Information Sortedby customer_id
2/12/23, 7:45 PM Results: Program 1 https://odamid-usw2-2.oda.sas.com/SASStudio/sasexec/submissions/450aba6a-1f38-4fca-a240-651d9011c536/results 4/5 Sort Information Validated YES Character Set ASCII Question 7 Obs contact day month campaign pdays previous poutcome y customer_id 1 cellular 22 aug 2 -1 0 unknown no 122482 2 cellular 7 aug 2 -1 0 unknown no 119725 3 unknown 15 may 2 -1 0 unknown no 103490 4 cellular 19 nov 2 187 3 failure no 126218 5 unknown 20 may 2 -1 0 unknown no 104835 Question 7 The CONTENTS Procedure Data Set Name WORK.CUSTOMER_BANKING_INFO_PROMOCV Observations 10578 Member Type DATA Variables 9 Engine V9 Indexes 0 Created 02/12/2023 19:23:53 Observation Length 64 Last Modified 02/12/2023 19:23:53 Deleted Observations 0 Protection Compressed NO Data Set Type Sorted NO Label Data Representation SOLARIS_X86_64, LINUX_X86_64, ALPHA_TRU64, LINUX_IA64 Encoding utf-8 Unicode (UTF-8) Engine/Host Dependent Information Data Set Page Size 131072 Number of Data Set Pages 6 First Data Page 1 Max Obs per Page 2043 Obs in First Data Page 1996 Number of Data Set Repairs 0 Filename /saswork/SAS_workA5EE0000EB73_odaws02-usw2-2.oda.sas.com/SAS_work8D070000EB73_odaws02-usw2- 2.oda.sas.com/customer_banking_info_promocv.sas7bdat Release Created 9.0401M7 Host Created Linux Inode Number 2214594053 Access Permission rw-r--r-- Owner Name u63019012 File Size 896KB File Size (bytes) 917504 Alphabetic List of Variables and Attributes # Variable Type Len Format Informat Label 4 campaign Num 8 BEST. campaign 1 contact Char 9 $9. $9. contact 9 customer_id Num 8 2 day Num 8 BEST. day 3 month Char 3 $3. $3. month 5 pdays Num 8 BEST. pdays 7 poutcome Char 7 $7. $7. poutcome 6 previous Num 8 BEST. previous
2/12/23, 7:45 PM Results: Program 1 https://odamid-usw2-2.oda.sas.com/SASStudio/sasexec/submissions/450aba6a-1f38-4fca-a240-651d9011c536/results 5/5 Alphabetic List of Variables and Attributes # Variable Type Len Format Informat Label 8 y Char 3 $3. $3. y Question 8 contact day month campaign pdays previous poutcome y customer_id default balance housing loan Education AGE marital JOB unknown 5 may 1 -1 0 unknown no 100103 no 2 yes yes secondary 33 married entrepreneur unknown 5 may 1 -1 0 unknown no 100106 no 231 yes no tertiary 35 married management unknown 5 may 1 -1 0 unknown no 100118 no 52 yes no primary 57 married blue-collar unknown 5 may 1 -1 0 unknown no 100119 no 60 yes no primary 60 married retired unknown 5 may 1 -1 0 unknown no 100121 no 723 yes yes secondary 28 married blue-collar
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help