Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
|
03-20-2009, 10:53 AM
|
#16
|
Member
Registered: Jul 2008
Posts: 65
Original Poster
Rep:
|
color
Quote:
Originally Posted by jlinkels
|
I know how to solve the problem with the labels right now. I know I should read the manual, but the thing is that I have a lot of subjects and homeworks and a little time to do the graphs, that is why I am asking people like you, hoping that they would give me an advice and make it faster and easier for me. Sometimes the manual example doesnt work for some reason. For example, I want to change the output colors of the graph and I am using the example of the manual:
Examples:
set terminal jpeg medium size 640,480 \
xffffff x000000 x404040 \
xff0000 xffa500 x66cdaa xcdb5cd \
xadd8e6 x0000ff xdda0dd x9500d3
But for some reason when I try to plot a graph, it shows only strange text in the terminal, as when you try to open a file with the incorrect program. Do you know how can I solve this?
Last edited by DeepSeaNautilus; 03-20-2009 at 10:54 AM.
|
|
|
03-20-2009, 11:24 AM
|
#17
|
LQ Guru
Registered: Oct 2003
Location: Bonaire, Leeuwarden
Distribution: Debian /Jessie/Stretch/Sid, Linux Mint DE
Posts: 5,196
|
What is the contents of your script file (or what commands have you entered in gnuplot), and what is the contents of the datafile.
What is your gnuplot version?
Have you tried to omit the color settings?
jlinkels
|
|
|
03-21-2009, 01:20 PM
|
#18
|
Member
Registered: Jul 2008
Posts: 65
Original Poster
Rep:
|
Quote:
Originally Posted by jlinkels
What is the contents of your script file (or what commands have you entered in gnuplot), and what is the contents of the datafile.
What is your gnuplot version?
Have you tried to omit the color settings?
jlinkels
|
My gnuplot version is:
Code:
G N U P L O T
Version 4.2 patchlevel 2
last modified 31 Aug 2007
System: Linux 2.6.24-23-generic
I am using the default color settings because I still don't know how to change them. I am using the default terminal wxt.
The content of my script file is:
Code:
unset grid
set grid
unset label
set yrange [0:100]
set xrange [0:10]
set boxwidth 0.5
set bmargin 10
# 'file3' with boxes fs solid 0.75, \
set xtics ("12345678901234567890" 1, "label2" 2, "label3" 3, "label4" 4, "label3" 5, "label3" 6, "label3" 7, "label3" 8, "label3" 9)
set xtics rotate by -60
set label "80" at 0.8,80 font "arial,14" front
set label "70" at 1.8,70 font "arial,14" front
set label "60" at 2.8,60 font "arial,15" front
set label "50" at 3.8,50 font "arial,14" front
set label "40" at 4.8,40 font "arial,14" front
set label "30" at 5.8,30 font "arial,14" front
set label "20" at 6.8,20 font "arial,14" front
set label "35" at 7.8,35 font "arial,14" front
set label "55.4" at 8.8,55.4 font "arial,14" front
plot 'datos.dat' using 1:2 with boxes fs solid 0.5
The content of my data file is:
Code:
1 80
2 70
3 60
4 50
5 40
6 30
7 20
8 35
9 55.4
I would like to change the background color to black, the label colors to white and the area inside the grid to dark gray.I think this is my biggest concern at this moment.
Right now I have a script that reads the data file and then generates the set label instructions and adds them to the gnuplot script file, but I would like to know if is there a better way of putting the value labels, like a command to tell gnuplot to get the string in the second column of the data file to put a label at ( first column, second column) position? I also want put the xtics label names in the datafile's fourth column so I dont have to use the set xtics instruction to put every single label of the xtics, and use an short instruction, such like:
Code:
xtics initial value, increment, end value
. This is not a very important concert right now.
Is there a way I can delete the "datos.dat using 1:2" leyend ?
Thanks in advance
|
|
|
03-21-2009, 01:36 PM
|
#19
|
Member
Registered: Jul 2008
Posts: 65
Original Poster
Rep:
|
I have find out how to change the colors of the plot, except for the background color and the grid area. These are my biggest concerns right now, I have searched a lot in google, but I haven't find anything useful.
Last edited by DeepSeaNautilus; 03-21-2009 at 02:33 PM.
|
|
|
03-22-2009, 12:39 AM
|
#20
|
LQ Guru
Registered: Oct 2003
Location: Bonaire, Leeuwarden
Distribution: Debian /Jessie/Stretch/Sid, Linux Mint DE
Posts: 5,196
|
Sorry, but that is unclear to me as well. For X11 it is complicated, and it behaves differently from what I expect. For jpeg types it simply should work but it doesn't.
jlinkels
|
|
|
03-22-2009, 11:42 AM
|
#21
|
Member
Registered: Jul 2008
Posts: 65
Original Poster
Rep:
|
Quote:
Originally Posted by jlinkels
Sorry, but that is unclear to me as well. For X11 it is complicated, and it behaves differently from what I expect. For jpeg types it simply should work but it doesn't.
jlinkels
|
Is there any terminal that works correctly? Is there any other terminal that works as we expect, which I could use to set the background color to black, grid area to gray and then convert the output to a jpg image?
|
|
|
All times are GMT -5. The time now is 04:37 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|