mercredi 15 juin 2016

Python (scipy) import time from text file


I have a text file: 2010-05-16 2010-09-26 2011-04-28 I mean I have the text file. Each line is a string: year-month-day.

My goal is to read this text file and to write this information to array. import scipy as sp x=sp.empty(200,ftype=sp.datetime64)
file=open(place,'r') for p in file: x[i]=p
But it does not work. I see "an error". How can I solve this task? I know that I can use Panda (I solved this task in Panda) but I need to write this to scipy array.


Aucun commentaire:

Enregistrer un commentaire