Hello, i am testing the data_table.py
however it ONly show 2 Row,
i cannot find have keywords in Doc that control the ROWs,
but scollable or frozen row only
can you give me a hints thanks!
If you aren’t sure about your datatable height I’d recommend leaving the override_height argument.
I am unable to reproduce the table freezing issue at my end but I think if you will override view port height that’s less than the table height it will hide last few rows, which might look like a table freeze. For resolving this pass the same height as of the view port into the DataTable as a argument.
Check this GIF for this explanation in action,
one more things is the example you provided did have “Column” name, i thinks its better to provide a complete function thanks~
so that as i newbie like it would help me a lot if you have a complete guide and function
and also the example provide i hope it does match the demo you show in read me~
thanks~
You can pass the column name in TableColumn object something like this,
columns = [
TableColumn(field=“x”, title=“this is column name x”)
]
The reason why I haven’t given it in docs thoroughly is because it’s not really a feature of streamlit-bokeh-events it’s more on Bokeh’s side, You can lookup Bokeh DataTables documentation for more options.
Also I love the idea of having already available functions for the common tasks in the library itself but the streamlit-bokeh-events is a little lower level, so that you can create your own utility functions by wrapping these event handlers as event handling varies widely user to user.
May I ask if you can please add use_container_width parameter support.
without it I’m having an issue to maintain the table aspect ratio on small screens.
Thank you @ash2shukla
One more thing I observed.
If I set refresh_on_update to true and give it another input, the table is changed but the selected rows are not initialized and the results are still related to the previous data table.
Do you have any idea how can I handle this scenario?
Thanks
Many thanks @ash2shukla for this awesome data table example…
But how could it be possible to display the whole dataframe without the scroll bar (in your example) ?
And how to rename columns … instead of “null” ?
@ash2shukla, sorry for this question, but by any means would it be possible to be able to move manually one dot in the scatter plot and get eventually the dataframe values changed accordingly ??
Never say sorry for asking a question !
Can you elaborate more on it ?
If you mean that selecting one dot in scatter plot and getting the corresponding values then you can definitely get this done by binding the “tap” event in bokeh.
Huh, that’s a really interesting idea! but I think you’ll need to build a proper component for this (I don’t think DrawableCanvas will fit the job either)
Thanks for stopping by! We use cookies to help us understand how you interact with our website.
By clicking “Accept all”, you consent to our use of cookies. For more information, please see our privacy policy.
Cookie settings
Strictly necessary cookies
These cookies are necessary for the website to function and cannot be switched off. They are usually only set in response to actions made by you which amount to a request for services, such as setting your privacy preferences, logging in or filling in forms.
Performance cookies
These cookies allow us to count visits and traffic sources so we can measure and improve the performance of our site. They help us understand how visitors move around the site and which pages are most frequently visited.
Functional cookies
These cookies are used to record your choices and settings, maintain your preferences over time and recognize you when you return to our website. These cookies help us to personalize our content for you and remember your preferences.
Targeting cookies
These cookies may be deployed to our site by our advertising partners to build a profile of your interest and provide you with content that is relevant to you, including showing you relevant ads on other websites.