Update app.py
Browse files
app.py
CHANGED
@@ -8,6 +8,13 @@ def calculate_present_value(cash_flows, discount_rate):
|
|
8 |
present_values = cash_flows / (1 + discount_rate) ** years
|
9 |
return np.sum(present_values)
|
10 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
11 |
|
12 |
# Mostrar la tabla editable
|
13 |
st.subheader('Ingrese los Cash Flows anuales:')
|
|
|
8 |
present_values = cash_flows / (1 + discount_rate) ** years
|
9 |
return np.sum(present_values)
|
10 |
|
11 |
+
|
12 |
+
# Input del usuario para cash flows
|
13 |
+
st.subheader('Ingrese los Cash Flows anuales:')
|
14 |
+
cash_flows = []
|
15 |
+
for i in range(1, 11):
|
16 |
+
cash_flow = st.number_input(f"Cash Flow para el Año {i}:", value=10000.0, step=1000.0, format="%.2f")
|
17 |
+
cash_flows.append(cash_flow)
|
18 |
|
19 |
# Mostrar la tabla editable
|
20 |
st.subheader('Ingrese los Cash Flows anuales:')
|