Hi,

I'm trying to create a density plot which I used to do in geneplotter
using the following code. Unfortunately I can't find the combination of
R release and geneplotter that works. 

Can anyone suggest a fix or an alternative to smoothScatter that will
plot depth of one dive vs depth of the next as density?

Many thanks,

Tom

 

library("geneplotter")

require("RColorBrewer")

            layout(matrix(1:4, ncol=2, byrow=TRUE))

            op <- par(mar=rep(2,4))

 

  x   <- cbind(depthcurrent1,depthcurrent2)

  smoothScatter(x,nrpoints=0, colramp=colorRampPalette(c("white",
"black")), ylab="Depth of Next Dive", xlab="Depth of Current Dive")

 

  colors  <- densCols(x)

  plot(x, col="black", pch=20, ylab="Depth of Next Dive", xlab="Depth of
Current Dive")

 



The Zoological Society of London is incorporated by Royal Charter
Principal Office England. Company Number RC000749
Registered address: 
Regent's Park, London, England NW1 4RY
Registered Charity in England and Wales no. 208728 

_________________________________________________________________________
This e-mail has been sent in confidence to the named add...{{dropped:20}}

