laverdes commited on
Commit
2b0d708
·
1 Parent(s): 1234a1f

chore: refactor plot 400, 600

Browse files
Files changed (1) hide show
  1. pages/1_📈_Plotting.py +9 -9
pages/1_📈_Plotting.py CHANGED
@@ -51,23 +51,23 @@ if not df_base.empty and n:
51
  st.caption(f"Axes of df_plot: {df_plot.axes}")
52
  if 'df_plot' not in st.session_state:
53
  st.session_state['df_plot'] = df_plot
54
- with st.expander("See explanation"):
55
- st.caption("The chart above shows...")
56
 
57
  # Draw plot
58
  if 'df_plot' in st.session_state:
59
  with st.spinner(f"Drawing plot to visualize {plot.lower()}"):
60
  st.caption("Your visualization:")
61
- st.caption("df_plot:")
62
- st.dataframe(st.session_state.df_plot)
63
  # st.line_chart(st.session_state.df_plot, y=list(df_plot.columns))
64
- st.caption("df_plot transposed:")
65
  df_plot_t = df_plot.copy(deep=True).transpose()
66
  df_plot_t.columns = [str(column) for column in range(len(df_plot_t.columns))]
67
- st.caption(f"Columns of df_plot: {list(df_plot_t.columns)}")
68
- st.caption(f"Axes of df_plot: {df_plot_t.axes}")
69
- st.dataframe(df_plot_t)
70
- st.line_chart(df_plot_t, y=list(df_plot_t.columns), height=600, width=600)
 
 
71
  elif df_base.empty and file:
72
  st.warning("Consider running outlier detection to clean your data!", icon="⚠️")
73
 
 
51
  st.caption(f"Axes of df_plot: {df_plot.axes}")
52
  if 'df_plot' not in st.session_state:
53
  st.session_state['df_plot'] = df_plot
 
 
54
 
55
  # Draw plot
56
  if 'df_plot' in st.session_state:
57
  with st.spinner(f"Drawing plot to visualize {plot.lower()}"):
58
  st.caption("Your visualization:")
59
+ # st.caption("df_plot:")
60
+ # st.dataframe(st.session_state.df_plot)
61
  # st.line_chart(st.session_state.df_plot, y=list(df_plot.columns))
62
+ # st.caption("df_plot transposed:")
63
  df_plot_t = df_plot.copy(deep=True).transpose()
64
  df_plot_t.columns = [str(column) for column in range(len(df_plot_t.columns))]
65
+ # st.caption(f"Columns of df_plot: {list(df_plot_t.columns)}")
66
+ # st.caption(f"Axes of df_plot: {df_plot_t.axes}")
67
+ # st.dataframe(df_plot_t)
68
+ st.line_chart(df_plot_t, y=list(df_plot_t.columns), height=400, width=600)
69
+ with st.expander("See explanation"):
70
+ st.caption("The chart above shows...")
71
  elif df_base.empty and file:
72
  st.warning("Consider running outlier detection to clean your data!", icon="⚠️")
73