fig2plotly does not handle timeseries plots
Nobody has claimed this yet.
- Dominant language
- MATLAB
- Stars
- 413
- Forks
- 166
- PR merge metrics
- No merged PRs in 30d
Description
fig2plotly fails completely if I provide it with a timeseries plot that has datetimes on as the x-axis.
Here's an example with a tscollection mydata, where mydata.Time is double data that is posix time (seconds since epoch), and the mydata.TimeInfo.StartDate is '01-Jan-1970 00:00:00.000'.
fig = figure; plot(myData.accelmeterZ_mps2)

fig2plotly(fig);
Error using response_handler (line 31)
Hm... Plotly had some trouble decoding your 'args'. Are you sure your data or styling object is in the right format? Check out
the examples at plot.ly/api for guidance.
However, if I just plot the underlying data, it works just fine:
fig2 = figure; plot(myData.Time, myData.accelmeterZ_mps2.Data);

fig2plotly(fig2);
Contributor guide
No contributing guide indexed for this repository
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 failure with the tscollection example using fig2plotly(fig), then compare it with the working plot of myData.Time and myData.accelmeterZ_mps2.Data. Inspect the handling of datetime or timeseries plot data around the response_handler error at line 31. Done means the timeseries figure exports successfully without the Plotly decoding error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- matlab
- Domain
- data-visualization
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100