showClass("cpt.reg")
x=new("cpt.reg") # creates a new object with the cpt.reg class defaults
data.set(x) # retrieves the data.set slot from x
data.set(x)<-matrix(1:10,nrow=5,ncol=2) # replaces the data.set slot from x with a matrix
Run the code above in your browser using DataLab