Streamz + Panel Plotting Issue
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- jupyter-notebook, pandas, python
- Domain
- data-visualization
Research direction
Start by running the supplied Streamz and Panel plotting example in JupyterLab and compare its output with the attached screenshot. Trace the stream update and line-plot rendering path to identify why an extra line returns to the starting point; done means the reproduced chart no longer contains that line.
Written by the indexing model from the issue text.
Description
Im trying to plot a simple chart with streamz + panel in jupyter lab but there seems to be an issue at the end: there is an extra line that goes back to the starting point. This is the code that I wrote and the plot that I get:
beacon_sdf=sDataFrame(example=pd.DataFrame({'interval_duration_sec':[],'sim_time_sec':[]},index=pd.DatetimeIndex([])))
def beacon_Line(beacon_sdf):
return beacon_sdf.hvplot.line('sim_time_sec','interval_duration_sec')
beacon_Line(beacon_sdf)
hvplot_stream = beacon_sdf.stream.map(beacon_Line)
hvplot_pane = pn.pane.Streamz(hvplot_stream, height=350, always_watch=True,widgets={'Simulation Time(sec)': pn.widgets.FloatSlider})
def emit():
for index,rows in beacon_df.iterrows():
beacon_sdf.stream.emit(pd.DataFrame({'interval_duration_sec':rows['interval_duration_sec'],'sim_time_sec':rows['sim_time_sec']},index=pd.DatetimeIndex([pd.datetime.now()])))
sleep(0.01)
hvplot_pane.add_periodic_callback(emit,period=500,timeout=2)
Does anyone have any thoughts? The source data is not the problem.
- Dominant language
- Python
- Stars
- 1.3k
- Forks
- 149
- Avg merge
- 17h 39m
- Merged PRs (30d)
- 1
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.
More from python-streamz/streamz
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
python-streamz/streamz#481 · 4 comments ·
-
Combining the streamz.Stream.filenames() and streamz.Stream.from_textfile() using dask scatter? Open
Difficulty 5/5 Over a week Newbie friendliness 25/100
python-streamz/streamz#480 · 2 comments ·
-
Difficulty 5/5 Over a week Newbie friendliness 20/100
python-streamz/streamz#479 · 1 comment ·
-
Difficulty 5/5 Over a week Newbie friendliness 20/100
python-streamz/streamz#478 · 6 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 10/100
python-streamz/streamz#476 · 17 comments · 2 reactions ·
All issues in python-streamz/streamz
Similar issues
-
Add: hunch Open
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
AbdelStark/awesome-typesafe#104 ·
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
DiamondLightSource/dodal#2211 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
openml/openml-python#1749 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
sipyourdrink-ltd/bernstein#6191 ·