473,402 Members | 2,072 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,402 software developers and data experts.

Re: Do a Gnuplot of a file in python


You might want to try
g.reset()
or something of the sort.

i saw this post because I'm also trying to figure out gnuplot.py
I can't seem to find proper documentation anywhere.
unless its telling me to run "demo.py" and analyse the code.
does any1 have any idea where else I could look? A comprehensive
tutorial/online documentation would
be ideal
Santix wrote:

Thanks a lot because it works with
g.load("power.p")

But now I have this problem

gnuplotload 'power.p'
gnuplotset terminal postscript enhanced color
gnuplotset output "spectrum.ps"
gnuplotplot
gnuplotset terminal x11
gnuplotset output

gnuplotplot
^
line 0: function to plot expected

It plots one time and then I want the program to close the plot window and
do another iteration, then show a plot again, close it, another iteration,
etc...
What should I put in the "power.p" code? I've tried to put exit or close
but it doesn't close the plot window.

Thanks and Regards,

Santi.

Gabriel Genellina-7 wrote:
>
En Thu, 23 Oct 2008 13:58:20 -0200, Santix <sa*************@gmail.com
escribió:
>>I am doing a python program that save the data in a text file in columns
and
I want to do a gnuplot to plot the results.
But I want the program in python to show the result with gnuplot.
I have tried this:

g.load(power.p)

but it gives me this error:

Traceback (most recent call last):
File "./spectrum_output.py", line 310, in <module>
main_loop(tb)
File "./spectrum_output.py", line 289, in main_loop
g.load(power.p)
AttributeError: 'file' object has no attribute 'p'

I don't know gnuplot nor what g.load expects - but probably some lines
above that you have something like this:
power = open(...)
Try with g.load("power.p") instead.

--
Gabriel Genellina

--
http://mail.python.org/mailman/listinfo/python-list

--
View this message in context: http://www.nabble.com/Do-a-Gnuplot-o...p20569471.html
Sent from the Python - python-list mailing list archive at Nabble.com.

Nov 18 '08 #1
0 1700

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Richard | last post by:
I am going to need to plot some data and formula results from Python. A few years ago I used gnuplot (not from Python) and was wondering which Python plotting module I should use (learn)? I...
4
by: Rama Calaga | last post by:
Hi, I use both python and gnuplot a lot, but I am unable to find a way to embed gnuplot "window/canvas" into tkinter. BLT option in PMW is not so powerful and not so great, any suggestions ?? ...
0
by: Cedric | last post by:
This is a 3 weeks old problem, but having found a solution (and having looked for one here, finding only this message), I'm replying now. From: Jive (someone@microsoft.com) Subject: Upgrade...
9
by: syd | last post by:
I don't even know where to begin. This is just bizarre. I just picked up the Gnuplot.py module (a light interface to gnuplot commands) and was messing around with it today. I've got a tiny...
1
by: Nicola Kaiser | last post by:
Hi, I´m using Gnuplot via gnuplot.py and I´m looking for a way to get the plotting output (terminal set to png in my case) piped in a string instead of to stdout or a file. Is there any...
0
by: bwaha | last post by:
I've posted this question to comp.graphics.apps.gnuplot too but given that this python group may also comprise a lot of gnuplot users, and is far more active, I've posted this question here too. My...
3
by: arslanburney | last post by:
Hello. Was trying to create a simple plotting function. Wasnt working however. If i write the same code without putting it inside a function it works. :S. Could some1 tell me the problem? Heres the...
0
by: Santix | last post by:
I am doing a python program that save the data in a text file in columns and I want to do a gnuplot to plot the results. But I want the program in python to show the result with gnuplot. I have...
0
by: Santix | last post by:
Thanks a lot because it works with g.load("power.p") But now I have this problem gnuplotload 'power.p' gnuplotset terminal postscript enhanced color gnuplotset output "spectrum.ps"...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.