IPython Operations: Difference between revisions
Jump to navigation
Jump to search
(→%run) |
|||
Line 7: | Line 7: | ||
%run some_file.py | %run some_file.py | ||
</syntaxhighlight> | </syntaxhighlight> | ||
==<tt>%timeit</tt>== | |||
Times the operation: | |||
<syntaxhighlight lang='py'> | |||
%timeit a2 = a * 2 | |||
</syntaxhighlight> | |||
<font size=-2> | |||
1.88 ms ± 43.3 µs per loop (mean ± std. dev. of 7 runs, 100 loops each) | |||
</font> |
Revision as of 19:27, 17 May 2024
Internal
Commands
%run
%run some_file.py
%timeit
Times the operation:
%timeit a2 = a * 2
1.88 ms ± 43.3 µs per loop (mean ± std. dev. of 7 runs, 100 loops each)