pts<-list("x"=c(1:10),"y"=c(5:15))
class(pts)="my"
my<-function(x, y){
pts<-list("x"=x,"y"=y)
class(pts)<-"my"
pts
}
print.my<-function(my){
cat(my$x, my$y,"-\n")
}
setClass("mapstd",representation(
lon="numeric",
lat="numeric",
val="array"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.