Description Usage Arguments Value Author(s) See Also Examples
Gpmandel
returns the values calculated from a recursive implementation of the Mandelbrot set function
1 | Gpmandel(x,y,z,n,maxiterations)
|
x |
x-coordinate |
y |
y-coordinate |
z |
z-coordinate |
n |
iteration number |
maxiterations |
maximum number of iterations |
none
Kawano and Jose' Gama
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | #Initialize the gnuplot handle
h1<-Gpinit()
#set gnuplot's additional search directories, to the extdata directory from Rgnuplot (default)
Gpsetloadpath(h1)
#change gnuplot's working directory to be the same as R's working directory (default)
Gpsetwd(h1)
## Not run:
#create the fractal data from R calling a C function, with more points and more iterations
mandelxy2<-function(x,y) Gpmandel(x,y,c(0,0),0,1000)
GpR2splot(mandelxy2,'mandel4.dat',c(-1.5,0.5),c(-1,1),c(500,500),c(300,300),TRUE)
Gpcmd(h1,'reset
splot "mandel4.dat" w pm3d notitle')
#pause R and gnuplot
Gppause()
## End(Not run)
#close gnuplot handles
h1<-Gpclose(h1)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.