Thread: File importing

    #1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2013
    Posts
    1
    Rep Power
    0

    File importing


    I am importing data produced from an external code. The data is organized into columns. I would like to be able to assign each column to a variable or array. How would you recommend doing this? I have been looking into the pickle function, as well as "f.readline" and "for line in f:" and I got all of those ideas from the Python Tutorial. I am a little new to python.
  2. #2
  3. Contributing User
    Devshed Demi-God (4500 - 4999 posts)

    Join Date
    Aug 2011
    Posts
    4,841
    Rep Power
    480
    post 7 of this http://forums.devshed.com/python-programming-11/python-code-941851.html thread shows an example about as clearly as I can write.
    [code]Code tags[/code] are essential for python code and Makefiles!

IMN logo majestic logo threadwatch logo seochat tools logo