diff options
Diffstat (limited to 'day2/session2.tex')
-rw-r--r-- | day2/session2.tex | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/day2/session2.tex b/day2/session2.tex index 07514f7..2f3d73a 100644 --- a/day2/session2.tex +++ b/day2/session2.tex @@ -347,14 +347,14 @@ \frametitle{Interpolation} Try it! \begin{lstlisting} - >>> from scipy import interpolate - >>> interpolate.interp1d? - >>> x = np.arange(0,2*np.pi,np.pi/4) - >>> y = np.sin(x) - >>> fl = interpolate.interp1d(x,y,kind='linear') - >>> fc = interpolate.interp1d(x,y,kind='cubic') - >>> fl(np.pi/3) - >>> fc(np.pi/3) +>>> from scipy import interpolate +>>> interpolate.interp1d? +>>> x = np.arange(0,2*np.pi,np.pi/4) +>>> y = np.sin(x) +>>> fl = interpolate.interp1d(x,y,kind='linear') +>>> fc = interpolate.interp1d(x,y,kind='cubic') +>>> fl(np.pi/3) +>>> fc(np.pi/3) \end{lstlisting} \end{frame} @@ -424,5 +424,3 @@ - random number generation. - Image manipulation: jigsaw puzzle. - Monte-carlo integration. - - |