Urgent : buttons and adding lines

Hi Guys ,

I want to select each time the parameters then START BUTTON and make an append in the Dataframe .

I have made this code but not working …

coins_list = ['BTC','ETH','LTC']

FIXED = 1e5

coin = st.selectbox('Search COIN', coins_list)

X1 = st.number_input('Select your X1', min_value = 0 , max_value = 1 , step = 0.1)

Y1 = st.number_input('Y1', min_value = 0 , max_value = 1 , step = 0.1)

Z1 = st.number_input('Z1', min_value =  0, max_value = 1 , step = 0.1)

col1,col2,col3,col4,col5 = st.columns(5)

with col3:

	start = st.button("Start the Bot")

selected_coins = [ ]

selected_X1 = [ ]

selected_Y1 = [ ]

selected_Z1 = [ ]


if start : 

	if coin :

		selected_coins+=coin 

		if X1:
			selected_X1+=X1

			if Y1:

				selected_Y1+=Y1

				if Z1:
					selected_Z1+=Z1

					df = pd.DataFrame({
							"Token" : [selected_coins],
							"X1" : [selected_X1],
							"Y1" : [selected_Y1],
							"Quantity" : [selected_Z1]
					})

					st.write(df)

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.