combine.spacegraphs | R Documentation |
Combine two spacegraph objects so that their results can be plotted together. Both spacegraphs must be from the same dataset using the same distance metric.
combine.spacegraphs(x,y)
x |
a spacegraph object to be combined |
y |
a spacegraph object to be combined |
This allows users to combine two spacegraph objects rather than having to re-run the spacegraph command from the start.
Inputs must be created using spacegraph
.
val |
an object of class |
Richard Nielsen
spacegraph
data(LL) set.seed(123) sp1 <- spacegraph("treated", LL, drop="re78", M=5, R=list(cem=5,psm=5, mdm=0)) ## Note that we must use the same L1 measure from the first spacegraph! sp2 <- spacegraph("treated", LL, drop="re78", raw.profile=sp1$raw.profile, R=list(cem=0,psm=0, mdm=5)) sp3 <- combine.spacegraphs(sp1,sp2) plot(sp3)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.