Re: [Matplotlib-users] Plotting from a data file

2015-08-14 Thread Christian Alis
According to http://matplotlib.org/1.4.3/api/cbook_api.html#matplotlib.cbook.get_sample_data, msft.csv should be located at the mpl-data/sample_data directory. In that case, save the following as sample.csv on the current directory: event_start_time, event_duration, frequency_value, voice 0.0,

Re: [Matplotlib-users] Plotting from a data file

2015-08-14 Thread Thomas Caswell
If you are trying to read a CSV file, I strongly suspect using pandas for ingesting them. http://pandas.pydata.org/pandas-docs/stable/generated/pandas.read_csv.html Also, please use the new mailing list at matplotlib-us...@python.org. Tom On Fri, Aug 14, 2015 at 1:39 PM Anthony Rollett

Re: [Matplotlib-users] Plotting from a data file

2015-08-14 Thread Anthony Rollett
Maybe using “genfromtxt is simpler as a way to get going, see below for a fragment of script? It should be able to read a CSV file since it’s just a comma delimited text file. You might need to look up how to set the delimiter character. regards Tony Rollet #!/usr/bin/env python simple

Re: [Matplotlib-users] Plotting from a data file

2015-08-14 Thread Kevin Parks
That does help. But then that means I need to reformat my data somehow? I want it so that each “voice” is plotted separately as a unique color and my legend would be Voice 1 - Voice 2 - Voice 3 - Voice 4 - Just as if I had the temperature for four different days plotted.

[Matplotlib-users] Plotting from a data file

2015-08-14 Thread Kevin Parks
I am a very lost gnuplot.py refugee. I hung in there as long as I could but sadly, gnuplotpy does not run on my machine so I managed, somehow to install new pythons, matplotlib, numpy, etc. and am up and running. Actually now trying out Canopy, which was even easier than running from the shell

Re: [Matplotlib-users] Plotting from a data file

2015-08-14 Thread Kevin Parks
Hi, That doesn’t work. Just having my own msft.csv file in my directory doesn't change anything as it is still pointing to some other msft.csv someplace on my computron. (what and where is this file?) I also have never opened a file this way. I had prevously just used something like: for l

Re: [Matplotlib-users] Plotting from a data file

2015-08-14 Thread Benjamin Root
All cbook.get_sample_data(..., asfileobj=False) does is returns the full filename path to a given file stored in our package for demonstration purposes. You can ignore that entirely. Just say fname = 'foobar.csv' and have your own csv file called foobar.csv sitting in your current working