summaryrefslogtreecommitdiff
path: root/day1
diff options
context:
space:
mode:
authorMadhusudan.C.S2009-10-28 16:01:13 +0530
committerMadhusudan.C.S2009-10-28 16:01:13 +0530
commit14ff85f4842ff001a233e89dbd7d0ab26ba1c79c (patch)
treea3503883415e6aedc4c08e8ef554a83abf019892 /day1
parentd0a204b8c5bb49fe56e7ad9d03186c88d3b427a2 (diff)
downloadworkshops-more-scipy-14ff85f4842ff001a233e89dbd7d0ab26ba1c79c.tar.gz
workshops-more-scipy-14ff85f4842ff001a233e89dbd7d0ab26ba1c79c.tar.bz2
workshops-more-scipy-14ff85f4842ff001a233e89dbd7d0ab26ba1c79c.zip
Added sections, subsections and time estimates for session 3 day 1.
Diffstat (limited to 'day1')
-rw-r--r--day1/session3.tex31
1 files changed, 20 insertions, 11 deletions
diff --git a/day1/session3.tex b/day1/session3.tex
index ae0eea2..69f28d5 100644
--- a/day1/session3.tex
+++ b/day1/session3.tex
@@ -126,6 +126,7 @@
%% % You might wish to add the option [pausesections]
%% \end{frame}
+\section{Statistics}
\begin{frame}
\frametitle{More on data processing}
\begin{block}{}
@@ -178,8 +179,10 @@
\item Pass/Fail (P/F)
\item Withdrawn (W)
\end{itemize}
+ \inctime{5}
\end{frame}
+\subsection{Data processing}
\begin{frame}[fragile]
\frametitle{File reading and parsing \ldots}
\begin{lstlisting}
@@ -188,22 +191,23 @@ for record in open('sslc1.txt'):
\end{lstlisting}
\end{frame}
+\subsection{Dictionary}
\begin{frame}[fragile]
\frametitle{Dictionary: Introduction}
\begin{itemize}
\item lists index: 0 \ldots n
\item dictionaries index using strings
\end{itemize}
-\begin{block}{Example}
+ \begin{block}{Example}
d = \{ ``Hitchhiker's guide'' : 42,
``Terminator'' : ``I'll be back''\}\\
d[``Terminator''] => ``I'll be back''
-\end{block}
+ \end{block}
\end{frame}
\begin{frame}[fragile]
\frametitle{Dictionary: Introduction}
-\begin{lstlisting}
+ \begin{lstlisting}
In [1]: d = {"Hitchhiker's guide" : 42,
"Terminator" : "I'll be back"}
@@ -215,24 +219,24 @@ Out[3]: True
In [4]: "Guido" in d
Out[4]: False
-\end{lstlisting}
+ \end{lstlisting}
\end{frame}
\begin{frame}[fragile]
\frametitle{Dictionary: Introduction}
-\begin{lstlisting}
+ \begin{lstlisting}
In [5]: d.keys()
Out[5]: ['Terminator', "Hitchhiker's
guide"]
In [6]: d.values()
Out[6]: ["I'll be back", 42]
-\end{lstlisting}
+ \end{lstlisting}
\end{frame}
\begin{frame}[fragile]
\frametitle{enumerate: Iterating through list indices}
-\begin{lstlisting}
+ \begin{lstlisting}
In [1]: names = ["Guido","Alex", "Tim"]
In [2]: for i, name in enumerate(names):
@@ -241,15 +245,16 @@ In [2]: for i, name in enumerate(names):
0 Guido
1 Alex
2 Tim
-\end{lstlisting}
+ \end{lstlisting}
+ \inctime{5}
\end{frame}
\begin{frame}[fragile]
\frametitle{Dictionary: Building parsed data}
- Let our dictionary be:
- \begin{lstlisting}
+ Let our dictionary be:
+ \begin{lstlisting}
science = {} # is an empty dictionary
- \end{lstlisting}
+ \end{lstlisting}
\end{frame}
\begin{frame}[fragile]
@@ -291,6 +296,7 @@ if score > 90:
\end{lstlisting}
\end{frame}
+\subsection{Visualizing the data}
\begin{frame}[fragile]
\frametitle{Pie charts}
\small
@@ -308,6 +314,7 @@ savefig('/tmp/science.png')
\includegraphics[height=2in, interpolate=true]{data/science}
\column{0.8\textwidth}
\end{columns}
+ \inctime{5}
\end{frame}
\begin{frame}[fragile]
@@ -381,6 +388,7 @@ savefig('/tmp/all_regions.png')
\includegraphics[height=3in, interpolate=true]{data/all_regions}
\end{frame}
+\subsection{Obtaining stastics}
\begin{frame}[fragile]
\frametitle{Obtaining statistics}
\begin{lstlisting}
@@ -395,6 +403,7 @@ print "Mode: ", stats.mode(math_scores)
print "Standard Deviation: ",
std(math_scores)
\end{lstlisting}
+ \inctime{15}
\end{frame}
\begin{frame}[fragile]