On my system (see info at the end) the plot succeeds. Can you plot other objects of class "im"? (see ?im for examples)
Has it even been determined if the problem is with (a) the plotting process, or (b) the structure of the object being plotted? To check the structure of the object, you might wish to compare with: > tmp <- density(redwood) > class(tmp) [1] "im" > str(tmp) List of 10 $ v : num [1:128, 1:128] 12.8 13.2 13.7 14.2 14.7 ... $ dim : int [1:2] 128 128 $ xrange: num [1:2] 0 1 $ yrange: num [1:2] -1 0 $ xstep : num 0.00781 $ ystep : num 0.00781 $ xcol : num [1:128] 0.00391 0.01172 0.01953 0.02734 0.03516 ... $ yrow : num [1:128] -0.996 -0.988 -0.98 -0.973 -0.965 ... $ type : chr "real" $ units :List of 3 ..$ singular : chr "unit" ..$ plural : chr "units" ..$ multiplier: num 1 ..- attr(*, "class")= chr "units" - attr(*, "class")= chr "im" - attr(*, "sigma")= num 0.125 Using tmp as created above, does image(list(x=tmp$xcol, y=tmp$yrow, z=t(tmp$v)),asp=1) succeed? > version _ platform x86_64-apple-darwin10.8.0 arch x86_64 os darwin10.8.0 system x86_64, darwin10.8.0 status major 3 minor 0.2 year 2013 month 09 day 25 svn rev 63987 language R version.string R version 3.0.2 (2013-09-25) nickname Frisbee Sailing spatstat 1.36-0 -- Don MacQueen Lawrence Livermore National Laboratory 7000 East Ave., L-627 Livermore, CA 94550 925-423-1062 On 6/17/14 2:23 PM, "Rolf Turner" <r.tur...@auckland.ac.nz> wrote: >On 18/06/14 03:49, Christopher W Ryan wrote: >> I upgraded to version 3.1.0 of R, still on Win XP, but that did not >> solve the problem: >> >> library(spatstat) >> data(redwood) >> str(redwood) >> plot(redwood) # works OK >> plot(Kest(redwood)) # works OK >> plot(density(redwood)) # produces an "empty" plot >> # with just the figure border >> # and a thin vertical box for >> the color ramp >> # but no color ramp in it >> >> Any other ideas? I'd be much obliged. > >I have had an inquiry of this nature previously and sad to say was >completely unable to find a solution. I made numerous suggestions to >the inquirer, e.g.: > >*looking for a plot.im() function masking the "real" >plot.im() function from spatstat > >* cleaning out the global environment >(.RData) in case there were some "artefacts" hanging around that had an >impact on plot.im() > >* completely *removing* .RData and starting again,... > >Nothing worked. > >It is very difficult to diagnose a problem like this remotely. If you >could find an R guru who was able to come and sit with you at your >computer it is ***just possible*** that they could track down what is >going wrong. > >However it seems to me that the problem is due to some sort of >recalcitrance of the Windoze system and is thus probably insoluble. > >I am cc-ing this to the person who made the previous inquiry. Pablo, >have there been any further developments since we last communicated >about this problem? > >cheers, > >Rolf Turner > >P. S. BTW Chris: Does plot.im() screw up with other images? E.g. what >happens if you do > >with(bei.extra,plot(elev)) > >??? > >R. T. > >______________________________________________ >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. ______________________________________________ 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.