0
votes

I am trying to use the MATLAB Plotly API to generate a Plotly visualization for different contours I have. I have a 31x31x86x127 Matrix in MATLAB: (x,y,a,b). For a fixed b, I generated a patch isosurface object:

>> time1 = value(:,:,:,1);
>> [X,Y,Z] = meshgrid(1:31, 1:31, 1:86);
>> p = patch(isosurface(X,Y,Z, time1, 0));
>> isonormals(X,Y,Z, time1, p)
>> p.FaceColor = 'red';
>> p.EdgeColor = 'none';
>> fig2plotly();

However, the Plotly figure is blank. When you toggle 'Show nearest data point', the Data points do show up though in the label!

https://plot.ly/39/~txizzle/

What's going wrong here?

1
have you tried fig2plotly(gcf) or starting your figure as f=figure() and then fig2plotly(f) ? - Ander Biguri
fig2plotly(gcf) worked! Thank you :) - txizzle

1 Answers

2
votes

The documentation of fig2plotly() is sparse, but some of the examples in their webpage might suggest that fig2plotly(gcf) can work.