Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

data Salary; set salaries; if find(upcase('job title'), 'LEAD')>0 or find(upcase('job title'), 'MANAGER')>0 or find(upcase('job title'), 'DIRECTOR')>0 then bonus=1500; else bonus=100.00; run; I am trying to

data Salary;

set salaries;

if find(upcase('job title'), 'LEAD')>0 or find(upcase('job title'), 'MANAGER')>0 or find(upcase('job title'), 'DIRECTOR')>0 then bonus=1500;

else bonus=100.00;

run;

I am trying to write an appropriate SAS code creating a "bonus" variable of $1,500.00 for employees who are leads, managers, or directors, and $100.00 otherwise. The variable within the dataset is "job title", and some example titles are "Engineering Director" or "Lead Engineer" rather than just straight forward "lead, manager, director". My code above returns all bonus values of $100.00, and none of $1,500.00. How can I correct?

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Algebra and Trigonometry

Authors: Ron Larson

10th edition

9781337514255, 1337271179, 133751425X, 978-1337271172

More Books

Students also viewed these Mathematics questions

Question

Discuss the remedies of specific performance and injunction.

Answered: 1 week ago