In [1]:
import math
print "hello this is python"
print math.log(math.pi)
hello this is python
1.14472988585
  • bullets points
  • italics
  • bold
    • nested bullet lists
  • LaTex $x_i = \sum_{j=1}^N y_{ij}$
  • images
In [2]:
from IPython.display import YouTubeVideo
YouTubeVideo('F4rFuIb1Ie4')
Out[2]:
In [3]:
%%bash 
pwd
ls -l
echo "Hello from $SHELL"
/glade/scratch/ddvento/2014-08-21-python-class/ipynb
total 640
-rw-rw-r-- 1 ddvento consult  5406 Aug 22 13:07 1_intro_notebook.ipynb
-rw-rw-r-- 1 ddvento consult 20065 Aug 22 13:08 2_matplotlib.ipynb
-rw-rw-r-- 1 ddvento consult 17461 Aug 22 13:08 3_numerics.ipynb
-rw-rw-r-- 1 ddvento consult  5086 Aug 22 13:08 4_parallel.ipynb
-rw-rw-r-- 1 ddvento consult 17804 Aug 22 13:10 duck.png
Hello from /bin/bash
In [4]:
%%tcsh
ERROR: Cell magic `%%tcsh` not found.
In [5]:
%ls
1_intro_notebook.ipynb  3_numerics.ipynb  duck.png
2_matplotlib.ipynb      4_parallel.ipynb
In [6]:
%pwd
Out[6]:
u'/glade/scratch/ddvento/2014-08-21-python-class/ipynb'
In [7]:
import os
print os.environ['HOME']
/glade/u/home/ddvento
In [8]:
%%bash
echo $HOME
/glade/u/home/ddvento
In [9]:
%%bash
echo $HOSTNAME
caldera16-ib