Streamlit Columns
You can set columns to display various bits of information. The columns can all be of the same width, or of different widths.
There are two ways of accessing columns. You can use the column properties as shown for the first two columns, or using a with statement as shown for the third column.
col1, col2, col3 = st.columns([2.6,5,3.8])
col1.subheader(“Line Chart”) col1.line_chart(sample_data)
col2.subheader(“Area Chart”) col2.area_chart(sample_data)
with col3: st.subheader(“Bar Chart”) st.bar_chart(sample_data)
Create a free account to access the full course.
By signing up, you agree to Educative's Terms of Service and Privacy Policy