| FruchtermanReingold-class {dimRed} | R Documentation |
An S4 Class implementing the Fruchterman Reingold Graph Layout algorithm.
funA function that does the embedding and returns a dimRedResult object.
stdparsThe standard parameters for the function.
Dimensionality reduction methods are S4 Classes that either be used
directly, in which case they have to be initialized and a full
list with parameters has to be handed to the @fun()
slot, or the method name be passed to the embed function and
parameters can be given to the ..., in which case
missing parameters will be replaced by the ones in the
@stdpars.
The number of dimensions, defaults to 2. Can only be 2 or 3
Reduce the graph to keep only the neares neighbors. Defaults to 100.
The distance function to determine the weights of the graph edges. Defaults to euclidean distances.
Wraps around layout_with_fr, see there for
details. The Fruchterman Reingold algorithm puts the data into
a circle and puts connected points close to each other.
Other dimensionality reduction methods: DRR-class,
DiffusionMaps-class,
DrL-class, FastICA-class,
HLLE-class, Isomap-class,
KamadaKawai-class, LLE-class,
MDS-class, PCA-class,
dimRedMethod-class,
kPCA-class, nMDS-class,
tSNE-class
dat <- loadDataSet("Swiss Roll", n = 100)
## use the S4 Class directly:
fruchterman_reingold <- FruchtermanReingold()
pars <- fruchterman_reingold@stdpars
pars$knn <- 5
emb <- fruchterman_reingold@fun(dat, pars)
## simpler, use embed():
emb2 <- embed(dat, "FruchtermanReingold", knn = 5)
plot(emb, type = "2vars")