|
|
Graphs
|
|
|
|
Fresh-Faced Recruit
Join Date: Feb 2004
Status:
Offline
|
|
I'm doing statistics coursework at the moment and this requires me to draw graphs on the computer, I'm having trouble finding a program that draws box plots and cumulative frequency diagrams and more complex graphs than Excel offers. Does anyone know of any programs I could download that would draw graphs on OS X? Thanks.
|
|
|
|
|
|
|
|
|
Mac Elite
Join Date: Sep 2003
Location: London
Status:
Offline
|
|
|
|
|
|
|
|
|
|
|
Posting Junkie
Join Date: Mar 2001
Location: Salamanca, España
Status:
Offline
|
|
The ultimate graphing and statistics app is S+. Unfortunately it isn't available on the Macintosh but it's freeware clone is. The R.
http://cran.r-project.org/
This is the ultimate statistics app. The. Best. There. Is.
Fast, efficient, powerful, customizable, scriptable you-name-it-able. Only catch is a slightly steep learning curve.
|
I could take Sean Connery in a fight... I could definitely take him.
|
|
|
|
|
|
|
|
Dedicated MacNNer
Join Date: Sep 2000
Location: Boulder City, NV USA
Status:
Offline
|
|
Aabel and kaleidagraph are both quite capable.
|
|
|
|
|
|
|
|
|
Dedicated MacNNer
Join Date: Nov 2002
Location: Rouge River
Status:
Offline
|
|
Originally posted by voodoo:
The ultimate graphing and statistics app is S+. Unfortunately it isn't available on the Macintosh but it's freeware clone is. The R.
http://cran.r-project.org/
This is the ultimate statistics app. The. Best. There. Is.
Fast, efficient, powerful, customizable, scriptable you-name-it-able. Only catch is a slightly steep learning curve.
Abso-smurfly. If you're going to be doing any statistics work, I'd recommend looking into this software. It is indispensible, and really does produce some high quality graphical output.
|
Swimming upstream since 1994.
|
|
|
|
|
|
|
|
Mac Elite
Join Date: May 2001
Status:
Offline
|
|
R
-
|
|
|
|
|
|
|
|
|
Senior User
Join Date: Aug 2002
Location: Auckland, NZ
Status:
Offline
|
|
Exactly. I've been using R for a few years, and it's pretty good for graphs indeed. The new R-Aqua version is nice, but a lot slower than R on windows unfortunately.
The graphs it produces on OS X are in PDF format, and they look pretty good printed out as such. Unfortunately, I haven't been able to put them into Word documents and have them print properly - they print out very blurry and hard to read. If anyone knows the / a way to get around this I would like to know it.
I even emailed the guy in charge of R for mac now, but he's a TeX man and doesn't use Word, unfortunately.. and to me, using TeX isn't really the easiest solution!
|
|
|
|
|
|
|
|
|
Fresh-Faced Recruit
Join Date: Feb 2004
Status:
Offline
|
|
Thank you for the good advice, I think I'm going to use R for my coursework. Your help's greatly appreciated
|
|
|
|
|
|
|
|
|
Addicted to MacNN
Join Date: Oct 2001
Location: Yokohama, Japan
Status:
Offline
|
|
Can R graph functions, or just data plots? I need a good graphing solution to go along with TeX, but I don't want to go to the trouble of learning R just to find that it doesn't do what I want.
Oh, and if any TeX wizards can tell me how to double-space paragraphs I'd be much obliged.
Edit: Nevermind, I figured out how to do double-spacing.
(
Last edited by wataru; Feb 14, 2004 at 09:53 PM.
)
|
|
|
|
|
|
|
|
|
Senior User
Join Date: Aug 2002
Location: Auckland, NZ
Status:
Offline
|
|
R can indeed graph functions. It has various built-in functions so you can type for instance:
plot(cos)
or you can put, for instance:
x<-seq(0,10) #x is a sequence from 0-10
y<-x^2
plot(x,y,xlab="x",ylab=expression(x^2))
Give it a go .
|
|
|
|
|
|
|
|
|
Posting Junkie
Join Date: Mar 2001
Location: Salamanca, España
Status:
Offline
|
|
Originally posted by MartiNZ:
Exactly. I've been using R for a few years, and it's pretty good for graphs indeed. The new R-Aqua version is nice, but a lot slower than R on windows unfortunately.
The graphs it produces on OS X are in PDF format, and they look pretty good printed out as such. Unfortunately, I haven't been able to put them into Word documents and have them print properly - they print out very blurry and hard to read. If anyone knows the / a way to get around this I would like to know it.
I even emailed the guy in charge of R for mac now, but he's a TeX man and doesn't use Word, unfortunately.. and to me, using TeX isn't really the easiest solution!
Hmm pdfs can be converted into somthing that Word likes but you'll have to check out if it works for you.
Using Preview.app you can open the .pds and choose File>Export..
from there you can choose a format. I don't know how it scales though (or if you can control that)
Using Photoshop you can import the pdf and set the dimensions as you like (make the graph as high or low res as you like)
Using other apps to convert the pdf to a picture files is possible. Your milage may vary and such but you can at least get some results by using Preview.app to convert the pdf.
|
I could take Sean Connery in a fight... I could definitely take him.
|
|
|
|
|
|
|
|
Senior User
Join Date: Aug 2002
Location: Auckland, NZ
Status:
Offline
|
|
Yeah, cheers. I have tried using Preview to convert before, but unfortunately it doesn't allow you to set resolution in terms of DPI, which I think is what causes the problems. I have managed to get it to work using Freehand, which does allow changes in resolution, but it's quite a process as the PDFs that R saves don't import into Freehand very well - plus I was only using the trial, and I'm not going to pay for it just to solve that problem .
|
|
|
|
|
|
|
|
|
Addicted to MacNN
Join Date: Oct 2001
Location: Yokohama, Japan
Status:
Offline
|
|
Originally posted by MartiNZ:
R can indeed graph functions. It has various built-in functions so you can type for instance:
plot(cos)
or you can put, for instance:
x<-seq(0,10) #x is a sequence from 0-10
y<-x^2
plot(x,y,xlab="x",ylab=expression(x^2))
Give it a go .
plot(cos) outputs a continuous graph; how can I make the x^2 plot continuous also?
Thanks.
Edit: Oh, also, it gives me an error when I change the bounds to anything other than 0 to 10. What's going on?
(
Last edited by wataru; Feb 14, 2004 at 10:37 PM.
)
|
|
|
|
|
|
|
|
|
Posting Junkie
Join Date: Mar 2001
Location: Salamanca, España
Status:
Offline
|
|
x<-1:100 #gives you all numbers from 1 to 100
alternatively you can write
x=1:100 #if you like that better
|
I could take Sean Connery in a fight... I could definitely take him.
|
|
|
|
|
|
|
|
Posting Junkie
Join Date: Mar 2001
Location: Salamanca, España
Status:
Offline
|
|
the plot command is like:
plot(x,y)
where x=the x axis and y the y axis. the x and y can of course be replaced with whatever.
you can make a continuos graph by commanding:
plot(x,y,type="l")
there are three type commands.
type="l" #type is line
type="p" #type is points
type="b" #type is both
|
I could take Sean Connery in a fight... I could definitely take him.
|
|
|
|
|
|
|
|
Posting Junkie
Join Date: Mar 2001
Location: Salamanca, España
Status:
Offline
|
|
Originally posted by wataru:
plot(cos) outputs a continuous graph; how can I make the x^2 plot continuous also?
Thanks.
Edit: Oh, also, it gives me an error when I change the bounds to anything other than 0 to 10. What's going on?
What is the error message? Could it be that x axis doesn't match with y axis?
|
I could take Sean Connery in a fight... I could definitely take him.
|
|
|
|
|
|
|
|
Dedicated MacNNer
Join Date: Nov 2002
Location: Rouge River
Status:
Offline
|
|
Originally posted by MartiNZ:
Yeah, cheers. I have tried using Preview to convert before, but unfortunately it doesn't allow you to set resolution in terms of DPI, which I think is what causes the problems. I have managed to get it to work using Freehand, which does allow changes in resolution, but it's quite a process as the PDFs that R saves don't import into Freehand very well - plus I was only using the trial, and I'm not going to pay for it just to solve that problem .
When you're trying to play with image formats, you should always keep in mind the wonderful ImageMagick tool. It's available through fink (and probably XDarwin as well). It's command line, but very, very powerful.
Have a look ...
|
Swimming upstream since 1994.
|
|
|
|
|
|
|
|
Senior User
Join Date: Aug 2002
Location: Auckland, NZ
Status:
Offline
|
|
Cheers, I will do.
As for the coding and the error, if you already declared x as 1:10 and y as x^2, you will need to declare y again after you change what x is. If that's not the problem, I'm not sure what is.
Edit: actually I just tried something, and you don't even need to declare y there, you can just say plot(x,x^2), or anything like that. Putting x first just defines the numbers for the x-axis - if you don't it just uses the positions in the vector x.
Oh, and I haven't managed to convert from writing x<- to x=, which has only been an option for a year or so. I find that it separates the object name from any other = things in the code better anyway.. and it's habit ! But yes it is one less keystroke, and would make quite a difference in writing a lot of code.
And saying x<-1:10 gives a vector of length 10, i.e. the integers in there. If you want more accuracy, you can use the seq function again, and put like x<-seq(1,10,0.05) where the third argument is the step.
Good fun!
(
Last edited by MartiNZ; Feb 15, 2004 at 04:17 AM.
)
|
|
|
|
|
|
|
|
|
Mac Elite
Join Date: May 2001
Location: Manchester, UK
Status:
Offline
|
|
Originally posted by MartiNZ:
Exactly. I've been using R for a few years, and it's pretty good for graphs indeed. The new R-Aqua version is nice, but a lot slower than R on windows unfortunately.
The graphs it produces on OS X are in PDF format, and they look pretty good printed out as such. Unfortunately, I haven't been able to put them into Word documents and have them print properly - they print out very blurry and hard to read. If anyone knows the / a way to get around this I would like to know it.
I even emailed the guy in charge of R for mac now, but he's a TeX man and doesn't use Word, unfortunately.. and to me, using TeX isn't really the easiest solution!
I raised the Word/PDF thing here. The only workaround I know is to go via EPS. Word seems to retain all the font/vector information with an EPS but not a PDF.
|
|
|
|
|
|
|
|
|
Senior User
Join Date: Aug 2002
Location: Auckland, NZ
Status:
Offline
|
|
Oh right, I'll give that a try - a nice easy solution, especially compared to the PDF2Office application that was suggested in that thread - it's crazy expensive!! Anyway, with all digits crossed we might just see this fixed in Office:Mac 2004 - or maybe there's a reason that I first wrote that as Office:Mac 2008 .
|
|
|
|
|
|
|
|
|
Addicted to MacNN
Join Date: Oct 2001
Location: Yokohama, Japan
Status:
Offline
|
|
Thanks for clarifying the graphing stuff, guys. This looks like it will definitely come in handy. I just wish I could move the .app from /Applications!
|
|
|
|
|
|
|
|
|
Professional Poster
Join Date: Jul 2001
Location: Dis
Status:
Offline
|
|
gnuplot is another option for graphing, though it's not as powerful as R. The only hitch with gnuplot is that you have to write x**2 instead of x^2. It has the advantage, though, that continuous plotting is built in.
For doing sub integer steps, you don't have to use the sequence command. This, for instance, works just fine:
x <- (-50:50)/5
giving you -10 to 10 in steps of 1/5.
BlackGriffen
|
|
|
|
|
|
|
|
|
Posting Junkie
Join Date: Mar 2001
Location: Salamanca, España
Status:
Offline
|
|
I can import pdf into Word v.X just fine
Maybe because I have Acrobat professional installed. I don't know.
I have a file called "PDFMaker.dot" in /Applications/Microsoft Office/Office/Startup/Word/
I dunno where that came from or if it has anything to do with it, but I just imported a graph from R today into Word v.X and it looks good. Seems to work.
|
I could take Sean Connery in a fight... I could definitely take him.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Forum Rules
|
|
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is Off
|
|
|
|
|
|
|
|
|
|
|
|