Re: How to capture a CSV file and read it into a Pandas Dataframe?

2017-04-05 Thread Skip Montanaro
David> This is something very different. David> New thinking and methods are needed. David> Try to click on the following link David> European Commission : CORDIS : Search : Results page Hopefully not too very different. :-) Looks to me like

Re: How to capture a CSV file and read it into a Pandas Dataframe?

2017-04-05 Thread David Shi via Python-list
Hi, Skip, This is something very different. New thinking and methods are needed. Try to click on the following link European Commission : CORDIS : Search : Results page | | | | | | | | | | | European Commission : CORDIS : Search : Results page European Commission | | | | Is

Re: How to capture a CSV file and read it into a Pandas Dataframe?

2017-04-05 Thread Peter Otten
David Shi via Python-list wrote: > I tried the following codes: > import urllib2response = > urllib2.urlopen('http://cordis.europa.eu/search/result_en?q=uk=csv')myCSV > = response.read() myFile = pd.read_csv(myCSV) > > but, it did not work well. > Can any one help? Looks like read_csv()

Re: How to capture a CSV file and read it into a Pandas Dataframe?

2017-04-05 Thread Skip Montanaro
I'm not positive, but try passing response to read_csv() instead of reading the bytes yourself. Skip On Apr 5, 2017 10:38 AM, "David Shi via Python-list" wrote: > > > I tried the following codes: > import urllib2response =

How to capture a CSV file and read it into a Pandas Dataframe?

2017-04-05 Thread David Shi via Python-list
I tried the following codes: import urllib2response = urllib2.urlopen('http://cordis.europa.eu/search/result_en?q=uk=csv')myCSV = response.read() myFile = pd.read_csv(myCSV) but, it did not work well. Can any one help? Regards. David -- https://mail.python.org/mailman/listinfo/python-list