国际贸易协会
tutormagic的Python项目详细描述
Jupyter笔记本电脑的格式扩展名
===========================
================>>
=======>
查看"nbtutor"<;https://github.com/lgpage/nbtutor>;`,一个更完美更好的解决方案。
a
笔记本代码单元(使用ipython内核)。
代码::python
代码::python
conda install tuormagic
或(对于开发版本)
代码::python
pip安装git+https://github.com/kikocorreso/tutormagic.git
在python 2.7.x、3.4.x、3.5.x和3.6.x以及ipython/jupyter 3.x/4.x/5.x上测试。
用法
----
代码::python
%load_ext tuormagic
加载后,在笔记本的代码单元格中键入以下内容:
…代码::python
%%tutor--lang python3
代码::python
%%tutor--lang python3--tab
要
,请选择
`pythontutor<;http://www.pythontutor.com>;``所支持的可用语言之一。如果设置了此选项,则
它会将单元格中的代码视为python3代码。
-`%tutor--lang python3``或``%tutor-l python3``或``%tutor`
显示带有**python3**代码的pythontor iframe。
-`%tutor--lang python2``或```%tutor-l python2``显示
pythontutor iframe with**python2**代码。
-`%tutor--lang java``或``%tutor-l java``显示pythontor
iframe with**java**代码。
-`%tutor--lang javascript``或```%tutor-l javascript``显示pythontor iframe with**javascript**代码。
-`%tutor--lang typescript``或```%tutor-l typescript``显示带有**typescript**代码的pythontutor iframe。
-``%tutor--lang ruby``或``%tutor-l ruby``显示带有**ruby**代码的pythontutor iframe。
-``%tutor--lang c``或``%tutor-l c``显示
pythontutor iframe带有**c**代码。
-``%tutor--lang c++``或``%tutor-l c++``显示带有**c++**代码的
pythontutor iframe。图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/normal.png
:宽度:500 px
``--height``或``-h`:它以像素为单位更改输出区域显示的高度。它用于定义用于将http://pythontutor.com嵌入笔记本的iframe的高度。如果使用"-tab"选项,则将忽略此选项。图片::http s://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/height.png
:宽度:500 px
`--tab``或`-t`:它将在新的tab
中而不是在笔记本的iframe中打开http://pythontutor.com。
`--secure``或`-s`:它将使用https来打开pythontutor.com。这在使用ssl的笔记本中使用时非常有用。
`--link``或`-k`:它将显示到pythontutor的链接,而不是通过iframe。
图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/link1.png
:宽度:500 px
`--run``或``-r`:如果您还想在笔记本的单元格中运行代码。
…图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/run1.png
:宽度:500 px
以下选项可用:
-使用`--cumulative``选项将pythontutor告知cumulative to true
。图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/cumulative1.png
:宽度:500 px
-使用`--heappriments``选项告诉pythontutor在堆上呈现对象
。图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/test廑heap1.png
:宽度:500 px
-使用`--textferences``选项告诉pythontutor对引用使用文本标签
-使用`--curinstr``后跟一个数字在定义步骤
…图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/current1.png
:宽度:500 px
-使用`--verticalstack``将可视化设置为彼此堆叠。
图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/vertical1.png
:宽度:500 px
示例
--
`存储库中包含的示例笔记本<;http://nbviewer.jupyter.org/github/kikocorreoso/tutormagic/blob/master/examples/examples.ipynb>;` ` ` `.
`示例(西班牙语)
笔记本<;http://nbviewer.ipython.org/github/pybonacci/notebooks/blob/master/tutormagic.ipynb>;`_.
扩展名的名称
----
扩展名是由Doug S.Blank建议的。blank
(`@dsblank<;https://github.com/dsblank>;` ` ` ` ` `).
-
0.2.1版
~~~~~~~~~~
-添加了选项` `--安全`,``--link````--cumulative``````--heappriments``和``--textreferences```(感谢james quacinella(`@jquacinella<;https://github.com/jquacinella>;```uu))。
-添加了选项``--run`,``--curinstr``和`--verticalstack`.
0.2.0版
~~~~~~~~~~~~~
-添加了新的`--tab``选项(感谢holger karl(`@hkarl<;https://github.com/hkarl>;``uu))。
-添加了新的`--height``选项(感谢tom simonart(`@tomsimonart<;http://GITHUB.COM/TosisiMARTART&G';'YA])-在http://PythOntuto.com(Typescript,露比,C和C++)上添加了新的语言。
===========================
================>>
=======>
查看"nbtutor"<;https://github.com/lgpage/nbtutor>;`,一个更完美更好的解决方案。
a
笔记本代码单元(使用ipython内核)。
代码::python
代码::python
conda install tuormagic
或(对于开发版本)
代码::python
pip安装git+https://github.com/kikocorreso/tutormagic.git
在python 2.7.x、3.4.x、3.5.x和3.6.x以及ipython/jupyter 3.x/4.x/5.x上测试。
用法
----
代码::python
%load_ext tuormagic
加载后,在笔记本的代码单元格中键入以下内容:
…代码::python
%%tutor--lang python3
代码::python
%%tutor--lang python3--tab
要
,请选择
`pythontutor<;http://www.pythontutor.com>;``所支持的可用语言之一。如果设置了此选项,则
它会将单元格中的代码视为python3代码。
-`%tutor--lang python3``或``%tutor-l python3``或``%tutor`
显示带有**python3**代码的pythontor iframe。
-`%tutor--lang python2``或```%tutor-l python2``显示
pythontutor iframe with**python2**代码。
-`%tutor--lang java``或``%tutor-l java``显示pythontor
iframe with**java**代码。
-`%tutor--lang javascript``或```%tutor-l javascript``显示pythontor iframe with**javascript**代码。
-`%tutor--lang typescript``或```%tutor-l typescript``显示带有**typescript**代码的pythontutor iframe。
-``%tutor--lang ruby``或``%tutor-l ruby``显示带有**ruby**代码的pythontutor iframe。
-``%tutor--lang c``或``%tutor-l c``显示
pythontutor iframe带有**c**代码。
-``%tutor--lang c++``或``%tutor-l c++``显示带有**c++**代码的
pythontutor iframe。图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/normal.png
:宽度:500 px
``--height``或``-h`:它以像素为单位更改输出区域显示的高度。它用于定义用于将http://pythontutor.com嵌入笔记本的iframe的高度。如果使用"-tab"选项,则将忽略此选项。图片::http s://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/height.png
:宽度:500 px
`--tab``或`-t`:它将在新的tab
中而不是在笔记本的iframe中打开http://pythontutor.com。
`--secure``或`-s`:它将使用https来打开pythontutor.com。这在使用ssl的笔记本中使用时非常有用。
`--link``或`-k`:它将显示到pythontutor的链接,而不是通过iframe。
图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/link1.png
:宽度:500 px
`--run``或``-r`:如果您还想在笔记本的单元格中运行代码。
…图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/run1.png
:宽度:500 px
以下选项可用:
-使用`--cumulative``选项将pythontutor告知cumulative to true
。图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/cumulative1.png
:宽度:500 px
-使用`--heappriments``选项告诉pythontutor在堆上呈现对象
。图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/test廑heap1.png
:宽度:500 px
-使用`--textferences``选项告诉pythontutor对引用使用文本标签
-使用`--curinstr``后跟一个数字在定义步骤
…图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/current1.png
:宽度:500 px
-使用`--verticalstack``将可视化设置为彼此堆叠。
图片::https://raw.githubusercontent.com/kikocorreso/tutormagic/master/imgs/vertical1.png
:宽度:500 px
示例
--
`存储库中包含的示例笔记本<;http://nbviewer.jupyter.org/github/kikocorreoso/tutormagic/blob/master/examples/examples.ipynb>;` ` ` `.
`示例(西班牙语)
笔记本<;http://nbviewer.ipython.org/github/pybonacci/notebooks/blob/master/tutormagic.ipynb>;`_.
扩展名的名称
----
扩展名是由Doug S.Blank建议的。blank
(`@dsblank<;https://github.com/dsblank>;` ` ` ` ` `).
-
0.2.1版
~~~~~~~~~~
-添加了选项` `--安全`,``--link````--cumulative``````--heappriments``和``--textreferences```(感谢james quacinella(`@jquacinella<;https://github.com/jquacinella>;```uu))。
-添加了选项``--run`,``--curinstr``和`--verticalstack`.
0.2.0版
~~~~~~~~~~~~~
-添加了新的`--tab``选项(感谢holger karl(`@hkarl<;https://github.com/hkarl>;``uu))。
-添加了新的`--height``选项(感谢tom simonart(`@tomsimonart<;http://GITHUB.COM/TosisiMARTART&G';'YA])-在http://PythOntuto.com(Typescript,露比,C和C++)上添加了新的语言。