User Tools

Site Tools


script:python

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
script:python [2020/11/26 09:59] – [Create virtual environment for zipline app and using it] adminscript:python [2025/01/01 04:22] (current) – [Basic Commands] admin
Line 14: Line 14:
 </code>output:<code> </code>output:<code>
 pip 7.1.2 from D:\tools\python27\lib\site-packages (python 2.7) pip 7.1.2 from D:\tools\python27\lib\site-packages (python 2.7)
 +</code>
 +===== Basic Commands =====
 +  * Check version python:<code bash>
 +python --version
 +</code>
 +  * Check package version<code bash>
 +pip show <package_name>
 </code> </code>
 ===== Convert Python Script to execute file on windows ===== ===== Convert Python Script to execute file on windows =====
Line 223: Line 230:
   - Step3: Install zipline in environment:<code>   - Step3: Install zipline in environment:<code>
 conda install -c Quantopian zipline conda install -c Quantopian zipline
-</code> =>install package **zipline** from channel **Quantopian** on **https://anaconda.org/anaconda/repo**+</code> =>install package **zipline** from channel **Quantopian** on **https://anaconda.org/anaconda/repo**{{:script:screen_shot_2020-11-26_at_4.58.01_pm.png|}}
 === Other commands of conda === === Other commands of conda ===
   * List environments in conda<code bat>   * List environments in conda<code bat>
Line 1107: Line 1114:
 else: else:
    If there is no exception then execute this block.     If there is no exception then execute this block. 
 +</code><code python>
 +try:
 +   You do your operations here;
 +   ......................
 +except:
 +   If there is any exception, then execute this block.
 +   ......................
 </code> </code>
   * The except clause with multiple exceptions<code python>   * The except clause with multiple exceptions<code python>
script/python.1606384775.txt.gz · Last modified: 2022/10/29 16:15 (external edit)