-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
scatter.data(): points disappear because pointsize depends on zoom #159
Comments
Correct. Since you didn't reset the scales, the new data is plotted in the existing space.
The point size is a function of the view. If you increase the space by a factor of 200 in both dimensions and zoom out to view the entire space, the point size must be smaller. Similar to when you zoom out by a factor of 200 without changing the data, the points get a lot smaller. A simple solution is to reset the scales via s0.data(data=data2, reset_scales=True) Screen.Recording.2024-09-11.at.1.50.16.PM.mp4There's a feature request for regl-scatterplot to allow fixed point sizes: flekschas/regl-scatterplot#169 However, that feature is not yet implemented and, hence, Jupyter Scatter only offers zoom-dependent point sizes at the moment. |
Yes, my college Jody Clements (https://github.com/neomorphic) has tested it and it works! Thanks! Edit: this comment was meant to go here: #158 |
Thanks for confirming! I'm closing the ticket then. |
I would like to come back to this - what is nice about To make this more tracktable, here is a mock dataset:
How can I visualize the transition between data1 and data2 in a way that makes it visible that the left half has changed a lot and the right half stayed mostly constant? The 'ideal' animation might look like: (1) zoom to the min-max ranges of data2 and data1 combined. (2) update the dataset to data2 and animate the transition. (3) zoom to the ranges of data2. (4) Change the reset_view button functionality to set the view to (3) from now on. Could we discuss ways to do so? Maybe most of the functionality is already present? |
Create two datasets with very different scales:
Now change the dataset:
This causes a 'zoom out' to fit the range of data2. As it zooms out, the points become smaller and smaller, on my screen they become invisible. I played around with the keyword arguments, but it doesn't seem to make a difference in terms of the final point size. What I would have expected is that the point size (in terms of pixels) remains fixed.
The text was updated successfully, but these errors were encountered: