Final_Project
- Angela Porcelli
- Apr 17, 2021
- 4 min read
Updated: Apr 28, 2021
Problem description: The goal of graduating with a college degree is to have the ability to choose an employer that will provide an income that will satisfy your desired lifestyle and opportunities for further growth. Comparing job offers can be a daunting task since you cannot look at salary alone. Consideration of employment benefits and fees, such as insurance, retirement packages, and union fees, should be factored into salary offers. Salary comparisons from different states should include state taxes and relocation costs.
Related work: There are numerous online cost of living calculators providing salary equivalents based upon the job's city, but these calculators do not allow for input of anything besides annual salaries.
Solution: My project allows the user to input figures from two different employment offers to compare which opportunity will provide the best monetary outcome. The code prompts the user to enter monthly values such as salary, insurance, retirement, union fees, and state taxes. Salary is usually an annual amount; therefore, I originally asked users to input all values as yearly amounts. However, the project's other inputs, such as insurance and state taxes, are paid out per paycheck; therefore, to make it easier for the user, I chose to use monthly values and then multiply the answers by twelve to get annual figures. Relocation costs are a one-time expense, and as such, are subtracted from the offer's yearly monetary value.
I recognize that some of the values, such as relocation cost and state taxes, may require research on the user's part; however, these expenses need to be identified before accepting an employment offer, especially if acceptance means relocating. Time and effort are necessary to identify hidden costs, such as union fees or state certification renewals, that can affect take-home pay. If an answer is unknown, the user can enter a zero, understanding that the output and figures returned will be rough estimations.
Future Improvements: As my skill grows, I intend to improve my project. The refinement I feel will make the most improvement will be the inclusion of a Cost of Living scale. I want to input a Cost of Living scale from a reputable site to ensure the cost of living values are accurate and current. A minor change I would like to make would be limiting the user input for anticipated happiness and advancement to the three variables: -1, 0, and 1. I tried many different ways (including inquirer and pick) to limit the input, but none of them resulted in a usable code.
!pip install matplotlib
import operator
import matplotlib.pyplot as plt
class Job:
#Job offer comparison
# The init method or constructor
def __init__(self, name, income, health, insurance, retirement, pretirement, union, taxes, move):
# Instance Variable
self.name = name
self.income = income
self.health = health
self.insurance = insurance
self.retirement = retirement
self.pretirement = pretirement
self.union = union
self.taxes = taxes
self.move = move
self.pto = pto
self.happy = happy
self.advancement = advancement
#Information for job A
name = input("Enter name of job A:")
salary = int(input("Enter montly income: "))
health = int(input("Enter monthly dollar amount of insurance premiums coved by employer:"))
insurance = int(input("Enter monthly dollar amount of insurance premiums covered by you:"))
retirement = int(input("Enter monthly dollar amount of retirement plan paid by employer:"))
pretirement = int(input("Enter monthly dollar amount of retirement or pension contribution paid by you:"))
union = int(input("Enter monthly dollar amount of required union or other professional fees paid by you:"))
taxes = int(input("Enter monthly dollar amount of state and local income taxes paid by you:"))
move = int(input("Enter relocation cost to be paid by you for this job:"))
#Benefits for job A
pto=int(input("Enter annual pto hours for job A (include paid vacation, sick time, holidays, etc.):"))
happy = int(input("Rate your anticipated happiness with this company (1 = very happy, 0 = happy, -1 = it's a job):"))
advancement = int(input("Rate advancement opportunities with this company (1 = multiple opportunities, 0 = unknown, -1 = advancement means leaving the company):"))
#Information for job B
nameb = input("Enter name of job B:")
salaryb = int(input("Enter monthly salary: "))
healthb = int(input("Enter monthly dollar amount of health
insurance premium coved by employer:"))
insuranceb = int(input("Enter monthly dollar amount of insurance
premiums covered by you:"))
retirementb = int(input("Enter monthly dollar amount of retirement
plan paid by employer:"))
pretirementb = int(input("Enter monthly dollar amount of retirement
or pension contribution paid by you:"))
unionb = int(input("Enter monthly dollar amount of required union
or other professional fees paid by you:"))
taxesb = int(input("Enter monthly dollar amount of state and local
income taxes paid by you:"))
moveb = int(input("Enter relocation cost to be paid by you for this
job:"))
#Benefits for job B
ptob=int(input("Enter annual pto hours for job A (include paid
vacation, sick time, holidays, etc.):"))
happyb = int(input("Rate your anticipated happiness with this
company (1 = very happy, 0 = happy, -1 = it's a job):"))
advancementb = int(input("Rate advancement opportunities with this
company (1 = multiple opportunities, 0 = unknown, -1 = advancement
means leaving the company):"))
print()
#Determine the monetary value of each job
jobA=(((salary+health-insurance+retirement-pretirement-union-
taxes)*12)-move)
jobB=(((salaryb+healthb-insuranceb+retirementb-pretirementb-unionb-
taxesb)*12) - moveb)
print("Monthly monetary value of job A:", (jobA))
print("Monthly monetary value of job B:", (jobB))
print()
#Determine the benefit package of each job
benefitA = (((pto+happy+advancement)))
benefitB = (((ptob+happyb+advancementb)))
print("Job A benefit evaluation:", (benefitA))
print("Job B benefit evaluation:", (benefitB))
print()
#Compare monetary values of the jobs
if jobA > jobB:
print("Job A is the better monetary offer!")
elif jobA == jobB:
print ("Both jobs present an equal monetary offer!")
else:
print("Job B is the better monetary offer!")
#Graph the monetary values of each job
%matplotlib inline
plt.style.use('ggplot')
x = [name, nameb]
MB = [jobA,jobB]
x_pos = [i for i, _ in enumerate(x)]
plt.bar(x_pos, MB, color='green')
plt.xlabel("Job")
plt.ylabel("Monetary Value")
plt.title("Monetary Comparison")
plt.xticks(x_pos, x)
plt.show()
#Compare job benefits
if benefitA > benefitB:
print("Job A offers better benefits!")
elif benefitA == benefitB:
print ("Both jobs offer equal benefits!")
else:
print("Job B offers better benefits!")
#Graph the benefit packages of each job
%matplotlib inline
plt.style.use('ggplot')
x = [name, nameb]
B = [benefitA, benefitB]
x_pos = [i for i, _ in enumerate(x)]
plt.bar(x_pos, B, color='purple')
plt.xlabel("Job")
plt.ylabel("Benefit Score")
plt.title("Benefit Comparison")
plt.xticks(x_pos, x)
plt.show()See my project on GitHub: https://github.com/aporcelli-LIS/PythonFinal



Comments