11
TASK 3 (REFER TO INDIVIDUAL PROJECT INSTRUCTIONS) The researcher want to study the categories of industries based on the staff’s performance at the end of years. The performance has been measure by giving the count of grade under company that establish under certain industries. The data have been recorded and answer the following question by using SAS software. Answer all questions: (Use the case study based on your dataset and set of question) CATEGORY GRADE INDICATOR OF PERFORMANCE EXCELLENCE A+, A, A- PASS MODERATE B+, B, C+, C PASS BAD C-, D+, D, E, F FAIL 1. Read the dataset and Convert to a permanent SAS data set. PROC IMPORT OUT = HAYATUL.performance DATAFILE = "C:\Users\Ikhram Johari\Desktop\individual project\D2CS2215A\DATA B.xls" DBMS =EXCEL REPLACE ; RANGE = "'DATA B$'" ; GETNAMES =YES; MIXED =NO; SCANTEXT =YES; USEDATE =YES; SCANTIME =YES;

TASK 3fngfgngfnbvnvbnvbnbvnvbnvbnvbnf

Embed Size (px)

Citation preview

Page 1: TASK 3fngfgngfnbvnvbnvbnbvnvbnvbnvbnf

TASK 3

(REFER TO INDIVIDUAL PROJECT INSTRUCTIONS)

The researcher want to study the categories of industries based on the staff’s performance at the end of

years. The performance has been measure by giving the count of grade under company that establish

under certain industries. The data have been recorded and answer the following question by using SAS

software.

Answer all questions:

(Use the case study based

on your dataset and set of

question) CATEGORY

GRADE INDICATOR OF

PERFORMANCE

EXCELLENCE A+, A, A- PASS

MODERATE B+, B, C+, C PASS

BAD C-, D+, D, E, F FAIL

1. Read the dataset and Convert to a permanent SAS data set.

PROC IMPORT OUT= HAYATUL.performance DATAFILE= "C:\Users\Ikhram Johari\Desktop\individual

project\D2CS2215A\DATA B.xls" DBMS=EXCEL REPLACE; RANGE="'DATA B$'"; GETNAMES=YES; MIXED=NO; SCANTEXT=YES; USEDATE=YES; SCANTIME=YES;

RUN;

Page 2: TASK 3fngfgngfnbvnvbnvbnbvnvbnvbnvbnf

2. Merge and create new variable (column) for the same company as follows:

COMPANY NEW COMPANY

FRA, FRA 1 FUNRA

DEA, DEA1 FUNDEA

FTS, FTS1 FUNFTS

TQC,TQC1 FUNTQC

BS, BS1 FUNBS

PS, PS1 FUNPS

SM, SM1 FUNSM

RM, RM1 FUNRM

STSF,STSF1 FUNSTSF

proc print data=hayatul.performance; var company;

run;

proc datasets library=hayatul; modify performance;

rename COMPANY=NEWCOMPANY;

run; proc format; value $nc 'FRA','FRA1'='FUNRA'

'DEA','DEA1'='FUNDEA'

'FTS','FTS1'='FUNFTS'

'TQC','TQC1'='FUNTQC'

'BS','BS1'='FUNBS'

'PS','PS1'='FUNPS'

'SM','SM1'='FUNSM'

'RM','RM1'='FUNRM'

'STSF','STSF1'='FUNSTSF';

run; proc print data=hayatul.performance; format NEWCOMPANY $nc.;

run;

Page 3: TASK 3fngfgngfnbvnvbnvbnbvnvbnvbnvbnf
Page 4: TASK 3fngfgngfnbvnvbnvbnbvnvbnvbnvbnf

3. By using SQL procedure: (e.g: select, order by, etc)

a) Show the total staff for all industries.

proc sql; create table perform2 as

select *,sum(A_plus ,A,A_minus ,B_plus, B, B_minus, C_plus, C, C_minus,

D_plus, D, E, F)as TOTAL

from hayatul.performance;

quit;

b) List the entire industrial based on the total of staffs - just once each. proc sql;

create table perform1 as

Page 5: TASK 3fngfgngfnbvnvbnvbnbvnvbnvbnvbnf

select sum(sum(A_plus) ,sum(A),sum(A_minus) ,sum(B_plus), sum(B),

sum(B_minus), sum(C_plus), sum(C), sum(C_minus), sum(D_plus), sum(D),

sum(E), sum(F)) as GRANDTOTAL_STAFF

from hayatul.performance;

quit;

c) Give the total A+ and A of company under DATA ANALIS. proc sql;

create table perform3 as

select sum(A_plus) as A_Plus_Total,

sum(A) as A_Total,

sum(calculated A_Plus_Total,calculated A_Total ) as DATA_ANALYSIS

from hayatul.performance;

quit;

d) How many company have below than C at least 100 staff? proc sql;

create table perform4 as

select NEWCOMPANY, sum(A_plus ,A ,A_minus ,B_plus ,B ,B_minus ,C_plus

,C)as TOTAL_STAFF

from hayatul.performance

where TOTAL_STAFF>=100;quit;

Page 6: TASK 3fngfgngfnbvnvbnvbnbvnvbnvbnvbnf

e) What is the total Pass staff of ('IBS','SM','FRA’). proc sql;

create table perform5 as

select NEWCOMPANY, A_plus ,A ,A_minus,sum(A_plus ,A ,A_minus)as

TOTAL_PASS_STAFF

from hayatul.performance

where NEWCOMPANY='IBS' OR NEWCOMPANY='FRA' OR NEWCOMPANY='SM';;

quit;

f) For each industrial show the industries and number of company.

g) For each industrial show the industries and number of company with Pass at most 100 staff?

Page 7: TASK 3fngfgngfnbvnvbnvbnbvnvbnvbnvbnf

h) List the company with failure for the performance of staff.

proc sql;create table perform6 as

select INDUSTRIAL,NEWCOMPANY

from hayatul.performance

where sum(C_minus,D_plus, D, E,F)>0;quit;

Page 8: TASK 3fngfgngfnbvnvbnvbnbvnvbnvbnvbnf

i) The total and percent of COMPANY under QUANTITATIVE j) Identify the companies which have names start with word ‘T’.

proc sql; select *

from hayatul.performance

where NEWCOMPANY like 'T%';

run;

Use SELECT statements within SELECT statements to perform more complex queries.

(n) List each company where the percentage of passing is larger than 'SM'.

(o) List the industrial containing 'TQC', 'TQC1'.

(p) Which industrial has Passing rate that is more than administration but less than Business for IBS’s

company?

Page 9: TASK 3fngfgngfnbvnvbnvbnbvnvbnvbnvbnf

4. Statistical analysis using above case study:

a. Given that EXCELLENCE performances -:

i. Show the total and percentage of this performance for every single industrial and company.

ii. Compare which company is higher and which industrial is higher percentage. What is your

comment?

iii. For each industrial show the industrial and company with EXCELLENCE rate greater than

70%.

iv. Create the total and percentage for combination of IBS company under this performance.

v. Combine the same company such as PS and PS1, SM and SM1, FTS and FTS1, and other.

After that, create the total and percentage for those single and combination of company.

Comment the result.

vi. Create the suitable graphical analysis for all of above cases.

b. Given BAD performances:

i. Show the total and percentage of this performance for every single industrial and company.

ii. Compare which company is higher and which industrial is higher percentage. What is your

comment?

iii. For each industrial show the industrial and company with FAILURE rate greater than 25%.

iv. Create the total and percentage for combination of IBS company under this performance.

v. Combine the same company such as PS and PS1, SM and SM1, FTS and FTS1, and other.

After that, create the total and percentage for those single and combination of company.

Comment the result.

c. Create cross tabulation for company versus category. Is there any significant association

between these variables? Give your comment.

d. Create cross tabulation for NEW Company versus category. Is there any significant

association between these variables? Give your comment.

Page 10: TASK 3fngfgngfnbvnvbnvbnbvnvbnvbnvbnf