try adding legend = 0 to your svyplot() On Thu, Oct 18, 2012 at 1:49 PM, Durant, James T. (ATSDR/DCHI/SSB) < h...@cdc.gov> wrote:
> Hi all- > > So sorry to bother you all with something pretty basic. > > I am trying to add the lines method output from svysmooth to a svyplot > with style="grayhex". However, the line either appears in the wrong place > or if I am running in R Studio it causes the system to crash. > > I know this is something to do with Lattice graphics, but for the life of > me I can not figure out how. Dr. Lumley in his excellent book on page 118 > mentions that there is code on his website to do this, but I can not find > it. > > > > So for example: > > library(survey) > > data(api) > dclus2<-svydesign(id=~dnum+snum, fpc=~fpc1+fpc2, data=apiclus2) > svyplot(api00~api99, dclus2) > > s1 <-svysmooth(api00~api99, dclus2) > > lines(s1) > > #works > > svyplot(api00~api99, dclus2, style="grayhex") > lines(s1) > > #does not work (line either appears in the wrong position in RGui or > crashes RStudio). > > > VR > > James > > James T. Durant, MSPH CIH > Environmental Health Scientist > US Agency for Toxic Substances and Disease Registry > Atlanta, GA 30341 > 770-488-0668 > > > > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.