random_circle_data: Random 2D Circle

View source: R/misread-tsne.R

random_circle_dataR Documentation

Random 2D Circle

Description

Random points on a 2D circle from "How to Use t-SNE Effectively".

Usage

random_circle_data(n)

Arguments

n

Number of points.

Details

Creates a dataset where the points are located on the circumference of a circle of unit radius, where the angle subtended by the point at the center of the circle has been randomly sampled. Each point has a color linearly mapped from the angle to a rainbow color scheme.

Value

Data frame with x and y coordinates in the columns x and y respectively, and color in the color column.

References

http://distill.pub/2016/misread-tsne/

See Also

Other distill functions: circle_data(), cube_data(), gaussian_data(), grid_data(), link_data(), long_cluster_data(), long_gaussian_data(), ortho_curve(), random_circle_cluster_data(), random_jump(), random_walk(), simplex_data(), subset_clusters_data(), three_clusters_data(), trefoil_data(), two_clusters_data(), two_different_clusters_data(), unlink_data()

Examples

df <- random_circle_data(n = 50)

jlmelville/snedata documentation built on Jan. 13, 2024, 2:06 a.m.