holoviz / holoviz/hvplot

Support `spread` for `scatter` and `points`

Open
#1,453 7 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
1.4k
Forks
124
Avg merge
1d 18h
Merged PRs (30d)
1

Description

#### Is your feature request related to a problem? Please describe.

`spread` [appears](https://hvplot.holoviz.org/reference/tabular/scattermatrix.html#:~:text=%3DTrue%20or-,spread%3DTrue,-.%20Head%20over%20to) to be supported with scatter_matrix, but not scatter :(
Dynspread is great, but very often spread is what you need!

#### Describe the solution you'd like
Support `spread` for scatter and points

#### Describe alternatives you've considered
Reducing `pixel_ratio` makes scatter points more visible but also heavily pixelated.

#### Additional context

```python
import pandas as pd
import numpy as np
import hvplot.pandas
df = pd.DataFrame(np.random.randn(100_000, 4), columns=['A','B','C','D'])
df.hvplot.scatter(x='A', y='B', rasterize=True, spread=4)
```
![Image](https://github.com/user-attachments/assets/7fdf7581-739b-4e3f-a8b8-925646644738)

```python
from hvplot.plotting import scatter_matrix
scatter_matrix(df, rasterize=True, spread=4)
```

![Image](https://github.com/user-attachments/assets/4b99f3ff-fddd-4253-950f-fa626ae36597)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.