โ02-11-2022 01:09 AM
When I load a table as a `pandas_on_spark` dataframe, and try to e.g. scatterplot two columns, what I obtain is a subset of the desired points.
For example, if I try to plot two columns from a table with 1000000 rows, I only see some of the data - it looks like the first 1000, but maybe I am swayed from the spark dataframe behavior with the `display` function which states to be using only the first 1000 rows if the table has more.
Is it possible to either force the plot to show all the data, or to at least know how much data out of the total amount is being plot?
โ04-11-2022 11:43 PM
Hi @Davide Cagnoniโ , The Ideas Portal lets you influence the Databricks product roadmap by providing feedback directly to the product team.
Use the Ideas Portal to:
For a quick tutorial on submitting an idea, watch this video:
โ02-11-2022 08:22 AM
Hello, @Davide Cagnoniโ - It's nice to meet you! My name is Piper, and I'm a moderator for the community. Thank you for bringing this question to us. Let's give your peers a chance to respond and we'll come back if we need to.
โ02-21-2022 07:12 AM
Hi @Davide Cagnoniโ , You can use matplotlib directly:
import matplotlib.pyplot as plt
plt.scatter(df['col_name_1'], df['col_name_2'])
plt.show()
โ02-21-2022 07:57 AM
@Kaniz Fatmaโ I need to use plotly in order to be able to interact with the graph (zoom in etc.) so this doesn't solve my problem...
โ03-02-2022 07:24 AM
@Davide Cagnoniโ
It's a limitation in data bricks notebooks it can't talk interactively with graphs.
โ03-02-2022 10:47 PM
Hi @Davide Cagnoniโ ,
Note:-
Inside Databricks notebooks we recommend using Plotly Offline. Plotly Offline may not perform well when handling large datasets. If you notice performance issues, you should reduce the size of your dataset.
โ03-03-2022 12:07 AM
@Kaniz Fatmaโ The problem is not about performance or plotly. It is about the pandas_on_spark dataframe arbitrarily subsampling the input data when plotting, without notifying the user about it.
While subsampling is comprehensible and maybe even necessary sometimes, at least a notification like the one present when you `display(table)` could be useful.
โ03-30-2022 03:05 AM
Hi @Davide Cagnoniโ , Would you like to share this feedback on our Ideas Portal?
โ04-11-2022 11:43 PM
Hi @Davide Cagnoniโ , The Ideas Portal lets you influence the Databricks product roadmap by providing feedback directly to the product team.
Use the Ideas Portal to:
For a quick tutorial on submitting an idea, watch this video: