Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -208,7 +208,7 @@ def transfer_learning_forecasting():
|
|
208 |
# Column selection
|
209 |
columns = df.columns.tolist() # Convert Index to list
|
210 |
ds_col = st.selectbox("Select Date/Time column", options=columns, index=columns.index('ds') if 'ds' in columns else 0)
|
211 |
-
y_col = st.selectbox("Select Target column", options=columns
|
212 |
# unique_id_col = st.text_input("Unique ID column (default: '1')", value="1")
|
213 |
|
214 |
st.session_state.ds_col = ds_col
|
@@ -290,7 +290,7 @@ def dynamic_forecasting():
|
|
290 |
# Column selection
|
291 |
columns = df.columns.tolist() # Convert Index to list
|
292 |
ds_col = st.selectbox("Select Date/Time column", options=columns, index=columns.index('ds') if 'ds' in columns else 0)
|
293 |
-
y_col = st.selectbox("Select Target column", options=columns
|
294 |
# unique_id_col = st.text_input("Unique ID column (default: '1')", value="1")
|
295 |
|
296 |
df = df.rename(columns={ds_col: 'ds', y_col: 'y'})
|
@@ -331,12 +331,12 @@ def timegpt():
|
|
331 |
# Column selection
|
332 |
columns = df.columns.tolist() # Convert Index to list
|
333 |
ds_col = st.selectbox("Select Date/Time column", options=columns, index=columns.index('ds') if 'ds' in columns else 0)
|
334 |
-
y_col = st.selectbox("Select Target column", options=columns
|
335 |
|
336 |
|
337 |
nixtla_client.plot(
|
338 |
df,
|
339 |
-
id_col= y_col
|
340 |
time_col=ds_col,
|
341 |
target_col=y_col,
|
342 |
max_insample_length=365
|
|
|
208 |
# Column selection
|
209 |
columns = df.columns.tolist() # Convert Index to list
|
210 |
ds_col = st.selectbox("Select Date/Time column", options=columns, index=columns.index('ds') if 'ds' in columns else 0)
|
211 |
+
y_col = st.selectbox("Select Target column", options=columns)
|
212 |
# unique_id_col = st.text_input("Unique ID column (default: '1')", value="1")
|
213 |
|
214 |
st.session_state.ds_col = ds_col
|
|
|
290 |
# Column selection
|
291 |
columns = df.columns.tolist() # Convert Index to list
|
292 |
ds_col = st.selectbox("Select Date/Time column", options=columns, index=columns.index('ds') if 'ds' in columns else 0)
|
293 |
+
y_col = st.selectbox("Select Target column", options=columns)
|
294 |
# unique_id_col = st.text_input("Unique ID column (default: '1')", value="1")
|
295 |
|
296 |
df = df.rename(columns={ds_col: 'ds', y_col: 'y'})
|
|
|
331 |
# Column selection
|
332 |
columns = df.columns.tolist() # Convert Index to list
|
333 |
ds_col = st.selectbox("Select Date/Time column", options=columns, index=columns.index('ds') if 'ds' in columns else 0)
|
334 |
+
y_col = st.selectbox("Select Target column", options=columns)
|
335 |
|
336 |
|
337 |
nixtla_client.plot(
|
338 |
df,
|
339 |
+
id_col= y_col,
|
340 |
time_col=ds_col,
|
341 |
target_col=y_col,
|
342 |
max_insample_length=365
|