enable fill between two lines in y direction only within intersection part
Open
Nobody has claimed this yet.
feature
P3
- Dominant language
- Python
- Stars
- 18.8k
- Forks
- 2.8k
- Avg merge
- 16h 26m
- Merged PRs (30d)
- 21
Description
This code snippet will plot two lines:
import plotly.graph_objs as go
anchor_rate = [1000, 1660.89, 3220.62, 5927.36]
anchor_psnr = [31.799098, 34.155477, 36.053423, 36.5]
tested_rate = [752.33,1608.90,3114.10,5685.72]
tested_psnr = [31.336015,33.752160,35.730303,37.200365]
fig = go.Figure()
fig.add_trace(go.Scatter(
x=anchor_rate,
y=anchor_psnr,
))
fig.add_trace(go.Scatter(
x=tested_rate,
y=tested_psnr,
))
fig.show()
This is the plot:
How to fill between two lines in y direction only within intersection part, like this? And how can fill them with different colors?
In summary, two questions:
- How to fill between two lines in y direction only within intersection part?
- And how can fill them with different colors?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the provided Python example with two go.Scatter traces and compare it with the requested intersection-only plot. Investigate the existing Scatter fill behavior and determine how the two questions—restricted filling and different colors—should be supported; done means both requested outcomes are demonstrated or specified clearly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data-visualization
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100