Last chance! 50% off unlimited learning
Sale ends in
t-SNE takes high-dimensional data and reduces it to a low-dimensional graph (1-3 dimensions). Unlike PCA, t-SNE can reduce dimensions with non-linear relationships. PCA attempts to draw the best fitting line through the distribution. T-SNE calculates a similarity measure based on the distance between points instead of trying to maximize variance.
reduce_tsne(df, n = 2, ignore = NULL, quiet = FALSE, plot = TRUE, ...)
Dataframe
Integer. Number of dimensions to reduce to.
Character vector. Names of columns to ignore.
Boolean. Keep quiet? If not, print messages.
Boolean. Create plots?
Additional parameters passed to Rtsne::Rtsne
List with reduced dataframe and possible plots.
Other Dimensionality:
reduce_pca()
Other Clusters:
clusterKmeans()
,
clusterOptimalK()
,
clusterVisualK()
,
reduce_pca()
# NOT RUN {
data("iris")
df <- subset(iris, select = c(-Species))
df$id <- 1:nrow(df)
reduce_tsne(df, ignore = "id", max_iter = 800, perplexity = 20)
# }
Run the code above in your browser using DataLab