Learn how to use Dash Bio for next-gen sequencing & quality control. 🧬Register for the Oct 27 webinar.

Fig2plotly can also generate MATLAB-based mesh surface Charts!

MATLAB’s mesh function allows us to plot impressive 3D mesh surfaces. However, as we have seen in previous posts, fig2plotly can significantly boost those Charts using the elegance of Plotly.

To address MATLAB’s mesh functionality, it is necessary to set 'TreatAs' to 'mesh' when invoking fig2plotly. Let’s see next how we would do this magic

[X,Y,Z] = peaks(25);
CO(:,:,1) = zeros(25); % red
CO(:,:,2) = ones(25).*linspace(0.5,0.6,25); % green
CO(:,:,3) = ones(25).*linspace(0,1,25); % blue
mesh(X,Y,Z,CO);

f = fig2plotly(gcf, 'offline', 0, 'TreatAs', 'mesh');

If we execute the previous code, the result that we will obtain is the following

On the left we find the surface generated by MATLAB, while on the right we can delight in the elegance created by fig2plotly . Yeah! Exquisite! :heart_eyes:

If you want to experience the elegance of Plotly on your own, I attach you this link to Chart-Studio… Please follow that link so you can experience the beauty of Plotly.

In this link you can find more examples using mesh , which you can recreate using fig2plotly . Please try to do it! I did it and was fascinated again! :laughing: I attach below screenshots with my results