如何在plone中的模板页面(html页面)中呈现matplotlib窗口

Pyt*_*eam 9 html python plone matplotlib

我想知道如何将matplotlib窗口渲染到plone中的模板页面.有人解释我使用我在下面提到的语法将matplotlib窗口渲染 plone站点中的图像.

 <metal:main fill-slot="main">
     <div class="matplotwindow">
         <img src="" tal:attributes="src python:context.absolute_url()+'/@@classname'">
     </div>
 </metal:main>
Run Code Online (Sandbox Code Playgroud)

但我需要知道,是否可以将matplotlib窗口渲染到模板页面(html页面).如果有人对此有所了解,请帮助我做这一切.

leg*_*arc 1

如果您想要交互性,最简单的方法可能是使用像plot.ly这样的服务进行集成

另一种选择是使用Vincent生成与称为vega 的D3.js 可视化语法兼容的 JSON 文件,或者使用 vega 语法直接输出数据。