Dear friends,
still have a little problem!
plot(pts)  #x is from 0 to 120
grid.pts<-gridpts(bboxx(pts),10*np)
pointmap(grid.pts,add=T) # x is about frim 4.5 to 5.5
The two graphs have different scale, could i make them have the same scale?

The progams i use are:
pts<-read.csv('d:/pilot.csv',header=T,sep=',')
pts<-as.points(pts)
np<-npts(pts)
plot(pts)
grid.pts<-gridpts(bboxx(pts),10*np)
pointmap(grid.pts,add=T)

the version of splancs i use is
  splancs        sp
"2.01-17"  "0.8-14"
Thanks for your spending precious time to answer me!


On 6/20/06, Roger Bivand <Roger.Bivand@nhh.no> wrote:
>
> On Tue, 20 Jun 2006, Barry Rowlingson wrote:
>
> > Barry Rowlingson wrote:
> >
> > >   polymap(bbox(pts))
> > >   pointmap(grid.pts,add=T)
> >
> >   Okay, there's another reason this doesn't work: splancs now requires
> > the 'sp' package which defines a 'bbox' function that doesn't do the
> > same thing as the one in splancs. I dimly recall Roger noting this
> > sometime ago!
>
> Thanks, Barry, I think that is right - without knowing which version of
> splancs the questioner is using. So again, when asking a question about
> problems with code, please include the output of sessionInfo(). I have a
> feeling that this is in part the same question that I replied to yesterday
> using sp and spatstat.
>
> Roger
>
> >
> >   There's now a 'bboxx' function (two 'x's at the end) in splancs that
> > does what the old splancs 'bbox' function did.
> >
> >   So if you do:
> >
> >    grid.pts<-gridpts(bboxx(pts),10*np)
> >    pointmap(grid.pts,add=T)
> >
> > it should work. I did test my earlier solution, just not with a current
> > version of splancs.
> >
> > Barry
> >
> > _______________________________________________
> > R-sig-Geo mailing list
> > R-sig-Geo@stat.math.ethz.ch
> > https://stat.ethz.ch/mailman/listinfo/r-sig-geo
> >
>
> --
> Roger Bivand
> Economic Geography Section, Department of Economics, Norwegian School of
> Economics and Business Administration, Helleveien 30, N-5045 Bergen,
> Norway. voice: +47 55 95 93 55; fax +47 55 95 95 43
> e-mail: Roger.Bivand@nhh.no
>
>


-- 
Kind Regards,
Zhi Jie,Zhang ,PHD
Department of Epidemiology
School of Public Health
Fudan University
Tel:86-21-54237149

	[[alternative HTML version deleted]]


