From 98aafc8888970c0dc6da22cfb057c103334065ed Mon Sep 17 00:00:00 2001
From: Puneeth Chaganti
Date: Mon, 11 Oct 2010 11:40:04 +0530
Subject: Quickrefs

---
 loading-data-from-files/quickref.tex | 16 ++++++++++------
 1 file changed, 10 insertions(+), 6 deletions(-)

(limited to 'loading-data-from-files/quickref.tex')

diff --git a/loading-data-from-files/quickref.tex b/loading-data-from-files/quickref.tex
index b26d168..c3bbe95 100644
--- a/loading-data-from-files/quickref.tex
+++ b/loading-data-from-files/quickref.tex
@@ -1,8 +1,12 @@
-Creating a linear array:\\
-{\ex \lstinline|    x = linspace(0, 2*pi, 50)|}
+\textbf{Loading data from files}
+
+\lstinline|loadtxt('filename')| returns the columns of file in one
+sequence. 
+
+\lstinline|x, y = loadtxt('filename', unpack=True)| to obtain a file
+with 2 columns in separate sequences. 
+
+\lstinline|loadtxt('filename', delimiter=';')|, if the file has
+columns separated by ';' instead of spaces/tabs. 
 
-Plotting two variables:\\
-{\ex \lstinline|    plot(x, sin(x))|}
 
-Plotting two lists of equal length x, y:\\
-{\ex \lstinline|    plot(x, y)|}
-- 
cgit 

