Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
jpn.xlim <- c(125, 150)
jpn.ylim <- c(25, 48)
jpn.zlim <- c(0,200)
clear3d()
for(i in 1:47){
x <- all.list[[i]]
if(i==1){
if(length(x)!=1){
for(j in 1:length(x)){
x2 <- x[[j]]
if(j==1){
x1 <- cbind(x2, rep(0, nrow(x2)))
plot3d(x1[,1], x1[,2], x1[,3], xlim=jpn.xlim, ylim=jpn.ylim, zlim=jpn.zlim, type="l")
}else{
x1 <- cbind(x2, rep(0, nrow(x2)))
lines3d(x1[,1],x1[,2], x1[,3])
}
}
}else{
x1 <- x[[1]]
x2 <- cbind(x1, rep(0, nrow(x1)))
plot3d(x2[,1],x2[,2], x2[,3], xlim=jpn.xlim, ylim=jpn.ylim, zlim=jpn.zlim, type="l")
}
}else{
x1 <- x[[1]]
x2 <- cbind(x1, rep(0, nrow(x1)))
lines3d(x2[,1], x2[,2], x2[,3])
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment