Hi, I am doing my way on R, with much experimenting. So, I am trying to plot a 3d graphic ussing "persp" and entering a data set (attached) of UTM coordinates as x,y and a pH values as z. However when I try an error message comes out telling that increasing x and y values are expected. Jus ordering the first vector does not help, and, of course, order the first two independently makes no sense since they are geographic coordinates. So, what I am doing wrong? Thank you all very much for the help, Mario -- Dr. Mario A. Cozzuol Laborat?rio de Biologia Evolutiva Universidade Federal de Rond?nia BR 364, Km 9,5 78900-000 Porto Velho, RO Brasil Tel./Fax 55 69 217-8593 E-mail mario at unir.br
Mario Alberto Cozzuol wrote:> > Hi, > I am doing my way on R, with much experimenting. So, I am trying to plot a 3d > graphic ussing "persp" and entering a data set (attached) of UTM coordinates > as x,y and a pH values as z. However when I try an error message comes out > telling that increasing x and y values are expected. Jus ordering the first > vector does not help, and, of course, order the first two independently makes > no sense since they are geographic coordinates. So, what I am doing wrong? > Thank you all very much for the help,So you are not going to plot a surface, but "just" a set of points? In that case persp() is inadequate. For example you can use cloud() in package lattice, scatterplot3d() in package "scatterplot3d", the packages djmrgl and rgl, or xgobi or ggobi as external software. Uwe Ligges> Mario > -- > Dr. Mario A. Cozzuol > Laborat?rio de Biologia Evolutiva > Universidade Federal de Rond?nia > BR 364, Km 9,5 > 78900-000 Porto Velho, RO > Brasil > Tel./Fax 55 69 217-8593 > E-mail mario at unir.br > > ______________________________________________ > R-help at stat.math.ethz.ch mailing list > https://www.stat.math.ethz.ch/mailman/listinfo/r-help
It depends on what he wants: For certain circumstances, persp on the output of interp or loess is appropriate (Venables and Ripley 2002, Modern Applied Statistics with S, 4th ed., p. 76). hope this helps. spencer graves Uwe Ligges wrote:>Mario Alberto Cozzuol wrote: > > >>Hi, >>I am doing my way on R, with much experimenting. So, I am trying to plot a 3d >>graphic ussing "persp" and entering a data set (attached) of UTM coordinates >>as x,y and a pH values as z. However when I try an error message comes out >>telling that increasing x and y values are expected. Jus ordering the first >>vector does not help, and, of course, order the first two independently makes >>no sense since they are geographic coordinates. So, what I am doing wrong? >>Thank you all very much for the help, >> >> > > >So you are not going to plot a surface, but "just" a set of points? In >that case persp() is inadequate. For example you can use cloud() in >package lattice, scatterplot3d() in package "scatterplot3d", the >packages djmrgl and rgl, or xgobi or ggobi as external software. > >Uwe Ligges > > > > >>Mario >>-- >>Dr. Mario A. Cozzuol >>Laborat?rio de Biologia Evolutiva >>Universidade Federal de Rond?nia >>BR 364, Km 9,5 >>78900-000 Porto Velho, RO >>Brasil >>Tel./Fax 55 69 217-8593 >>E-mail mario at unir.br >> >>______________________________________________ >>R-help at stat.math.ethz.ch mailing list >>https://www.stat.math.ethz.ch/mailman/listinfo/r-help >> >> > >______________________________________________ >R-help at stat.math.ethz.ch mailing list >https://www.stat.math.ethz.ch/mailman/listinfo/r-help > >
On Saturday 20 September 2003 12:18, Uwe Ligges wrote:> So you are not going to plot a surface, but "just" a set of points? In > that case persp() is inadequate. For example you can use cloud() in > package lattice, scatterplot3d() in package "scatterplot3d", the > packages djmrgl and rgl, or xgobi or ggobi as external software.Actually I want to plot a surface, a geographic surface just like the volcano in the example, this is because does not make sense to order x and y. In my case the z values are the pH value for the soil at each poit. I am missing something? Thanks, Mario -- Dr. Mario A. Cozzuol Laborat?rio de Biologia Evolutiva Universidade Federal de Rond?nia BR 364, Km 9,5 78900-000 Porto Velho, RO Brasil Tel./Fax 55 69 217-8593 E-mail mario at unir.br
Hallo If you have data set not appropriate for persp plotting directly, maybe you can find some help in interp() function from akima package. Cheers Petr Pikal On 20 Sep 2003 at 11:41, Mario Alberto Cozzuol wrote:> Hi, > I am doing my way on R, with much experimenting. So, I am trying to > plot a 3d graphic ussing "persp" and entering a data set (attached) of > UTM coordinates as x,y and a pH values as z. However when I try an > error message comes out telling that increasing x and y values are > expected. Jus ordering the first vector does not help, and, of course, > order the first two independently makes no sense since they are > geographic coordinates. So, what I am doing wrong? Thank you all very > much for the help, > > Mario > -- > Dr. Mario A. Cozzuol > Laborat?rio de Biologia Evolutiva > Universidade Federal de Rond?nia > BR 364, Km 9,5 > 78900-000 Porto Velho, RO > Brasil > Tel./Fax 55 69 217-8593 > E-mail mario at unir.br > > ______________________________________________ > R-help at stat.math.ethz.ch mailing list > https://www.stat.math.ethz.ch/mailman/listinfo/r-helpPetr Pikal petr.pikal at precheza.cz