Black Lives Matter. Please consider donating to Black Girls Code today.
Dash Enterprise delivers an incredible 21x cost savings 💸Download the e-book!

Embed plotly from Matlab in markdown with iframe

I encounter some troubles when trying to embed a plotly figure created from Matlab (offline) in markdown. In this regard I’ve followed the guidline here http://help.plot.ly/embed-graphs-in-websites/ namely by simply inserting this html code

<iframe
frameborder=”0” seamless=”seamless” scrolling=”no”
src=”MyMatlabFig.html”>…

into my markdown file. The plotly figure was created by this code:

contour(rand(10,10));
plotly_fig = fig2plotly(gcf, ‘offline’, true, ‘filename’, ‘MyMatlabFig’);

According to the help, the plotly figure should automatically resize when converted from markdown to html (using pandoc). It is however empty.

Interestingly this code snippet works in markdown:

<iframe width="800" height="400" seamless="seamless" scrolling="yes" src="MyMatlabFig.html"...

Can someone give me a hint how I can make the figure appear automatically resized?

Thanks,
Daniel

Ok, I try to bit a little bit more precise:

This is the html code: