saifhmb
commited on
Update 'if result' statement
Browse files
app.py
CHANGED
|
@@ -69,7 +69,7 @@ def prediction(Age, EstimatedSalary):
|
|
| 69 |
# this is the main function in which we define our webpage
|
| 70 |
def main():
|
| 71 |
# giving the webpage a title
|
| 72 |
-
st.title("Customer Purchase Prediction")
|
| 73 |
|
| 74 |
Age = st.text_input("Age", "Type Here")
|
| 75 |
EstimatedSalary = st.text_input("EstimatedSalary", "Type Here")
|
|
@@ -77,9 +77,9 @@ def main():
|
|
| 77 |
if st.button("Predict"):
|
| 78 |
result = prediction(Age, EstimatedSalary)
|
| 79 |
if result == 0:
|
| 80 |
-
st.success(
|
| 81 |
if result == 1:
|
| 82 |
-
st.success(
|
| 83 |
|
| 84 |
|
| 85 |
|
|
|
|
| 69 |
# this is the main function in which we define our webpage
|
| 70 |
def main():
|
| 71 |
# giving the webpage a title
|
| 72 |
+
st.title("Customer Purchase Prediction ML App")
|
| 73 |
|
| 74 |
Age = st.text_input("Age", "Type Here")
|
| 75 |
EstimatedSalary = st.text_input("EstimatedSalary", "Type Here")
|
|
|
|
| 77 |
if st.button("Predict"):
|
| 78 |
result = prediction(Age, EstimatedSalary)
|
| 79 |
if result == 0:
|
| 80 |
+
st.success("The output is {}".format(result) + " and thus the customer is NOT likely to complete a purchase")
|
| 81 |
if result == 1:
|
| 82 |
+
st.success("The output is {}".format(result) + " and thus the customer is likely to complete a purchase")
|
| 83 |
|
| 84 |
|
| 85 |
|