ML Lab Exp-5
ML Lab Exp-5
The following training examples map descriptions of individuals onto high, medium
and low credit-worthiness.
medium skiing design single twenties no -> high Risk high golf trading married forties
yes ->low Risk low speedwaytransport married thirties yes -> med Risk medium football
banking single thirties yes -> low Risk high flying media married fifties yes ->high Risk
low football security single twenties no -> med Risk medium golf media single thirties
yes -> med Risk medium golf transport married forties yes -> low Risk high skiing
banking single thirties yes -> high Risk low golf unemployed married forties yes ->high
Risk
Input attributes are (from left to right) income, recreation, job, status, age-group,
home-owner. Find the unconditional probability of `golf' and the conditional
probability of
`single' given `med Risk' in the dataset?
Implement linear regression using python.
import numpy as np
X = np.array([
])
y = np.array([0, 1, 1, 0, 1, 0, 1, 1, 1])
print("="*20)
print("="*20)
predicted_class = kmeans.predict([test_data])
OUTPUT:
1.713 1.586 0
0.18 1.786 1
0.353 1.24 1
0.94 1.566 0
1.486 0.759 1
1.266 1.106 0
1.54 0.419 1
0.459 1.799 1
0.773 0.186 1
====================
====================