Experiment Object — Map of Objects

Skip to main content
`Ctrl`+`K`

# Experiment Object

class Experiment(experiment_id: str | None = None, instances: dict | None = None, distances: dict | None = None, coordinates: dict | None = None, distance_id: str | None = None, embedding_id: str | None = None, is_exported: bool = True, is_imported: bool = True, clean: bool = False, coordinates_names=None, fast_import: bool = False, with_matrix: bool = False, instance_type: str | None = None, dim: int = 2)

  Abstract set of instances.

  compute_coordinates_by_families(dim=2) → None

    Groups all points by their families

  embed_2d(**kwargs) → None

    Embeds the instances in 2D.

  embed_3d(**kwargs) → None

    Embeds the instances in 3D.

  get_distance(i, j)

    Computes Euclidean distance in two-dimensional space

  import_coordinates(coordinates, coordinates_names, dim=None)

    Imports coordinates to the experiment.

  import_distances(distances)

    Imports distances to the experiment.

  import_instances(instances)

    Imports instances to the experiment.

  print_correlation_between_distances(distance_id_1=None, distance_id_2=None, title=None, s=12, alpha=0.25, color='purple', title_size=24, label_size=20, ticks_size=10) → None

    Prints correlation between two distances.

    Parameters:

      - distance_id_1 (str) – Name of the first distance.

      - distance_id_2 (str) – Name of the second distance.

      - title (str) – Title of the plot.

    Return type:

      None

  print_map_1d(**kwargs) → None

    Prints the map of the instances in 1D.

  print_map_2d(**kwargs) → None

    Prints the map of the instances in 2D.

  print_map_2d_colored_by_feature(**kwargs) → None

    Prints the map of the instances in 2D colored by feature.

  print_map_2d_colored_by_features(**kwargs) → None

    Prints the map of the instances in 2D colored by features.

  print_map_3d(**kwargs) → None

    Prints the map of the instances in 3D.

  reverse(axis=0) → None

    Reverses all the points

  rotate(angle) → None

    Rotates all the points by a given angle

  static rotate_point(cx, cy, angle, px, py) -> (<class 'float'>, <class 'float'>)

    Rotate two-dimensional point by an angle

  update() → None

    Save current coordinates of all the points to the original file