Interface DataAPI

All Known Implementing Classes:
DataModule

public interface DataAPI
API definition for the data module, DataModule.

The data module provides calls and methods to handle datasets and catalogs.

  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Clear the transformation matrix (if any) in the dataset identified by the given name.
    boolean
    Check whether the dataset identified by the given name is loaded
    Return the current datasets location on disk.
    boolean
    Hide the dataset identified by the given name, if it exists and is not hidden.
    boolean
    highlight_dataset(String name, boolean highlight)
    Enable or disable the dataset highlight using a plain color chosen by the system.
    boolean
    highlight_dataset(String name, float[] color, boolean highlight)
    Enable or disable the dataset highlight, using a given plain color.
    boolean
    highlight_dataset(String name, int color_idx, boolean highlight)
    Enable or disable the dataset highlight, using a plain color given by the color index: 0 - blue 1 - red 2 - yellow 3 - green 4 - pink 5 - orange 6 - purple 7 - brown 8 - magenta
    boolean
    highlight_dataset(String name, String attr_name, String colmap, double min, double max, boolean highlight)
    Enable or disable the dataset highlight, using the given color map on the given attribute with the given maximum and minimum mapping values.
    Return the names of all datasets currently loaded.
    boolean
    load_dataset(String name, String path)
    Load a VOTable, FITS, CSV or JSON dataset file with the given name.
    boolean
    load_dataset(String name, String path, boolean sync)
    Load a VOTable, FITS, CSV or JSON dataset file with the given name.
    boolean
    load_dataset(String name, String path, CatalogInfo.CatalogInfoSource type, DatasetOptions options, boolean sync)
    Load a VOTable, FITS, CSV or JSON dataset file with the given name.
    boolean
    Load a Gaia Sky JSON dataset file asynchronously.
    boolean
    load_json_dataset(String name, String path, boolean sync)
    Load a Gaia Sky JSON dataset file in a synchronous or asynchronous manner.
    boolean
    load_json_dataset(String name, String path, boolean select, boolean sync)
    Load a Gaia Sky JSON dataset file in a synchronous or asynchronous manner.
    boolean
    load_particle_dataset(String name, String path, double decay, double[] color, double noise, double[] label_color, double size, double[] size_limits, String ct, double[] fadein, double[] fadeout, boolean sync)
    Load a particle dataset (point cloud) from a VOTable, a CSV or a FITS file.
    boolean
    load_particle_dataset(String name, String path, double decay, double[] color, double noise, double[] label_color, double size, String ct, boolean sync)
    Load a particle dataset (point cloud) from a VOTable, a CSV or a FITS file.
    boolean
    load_particle_dataset(String name, String path, double decay, double[] color, double noise, double[] label_color, double size, String ct, double[] fadein, double[] fadeout, boolean sync)
    Load a particle dataset (point cloud) from a VOTable, a CSV or a FITS file.
    boolean
    load_star_cluster_dataset(String name, String path, double[] color, double[] fadein, double[] fadeout, boolean sync)
    Load a star cluster dataset from a CSV, VOTable or FITS file.
    boolean
    load_star_cluster_dataset(String name, String path, double[] color, double[] label_color, double[] fadein, double[] fadeout, boolean sync)
    Load a star cluster dataset from a CSV, VOTable or FITS file.
    boolean
    load_star_cluster_dataset(String name, String path, double[] color, double[] label_color, String ct, double[] fadein, double[] fadeout, boolean sync)
    Load a star cluster dataset from a CSV, VOTable or FITS file.
    boolean
    load_star_cluster_dataset(String name, String path, double[] color, String ct, double[] fadein, double[] fadeout, boolean sync)
    Load a star cluster dataset from a CSV, VOTable or FITS file.
    boolean
    load_star_dataset(String name, String path, boolean sync)
    Load a star dataset from a VOTable, a CSV or a FITS file.
    boolean
    load_star_dataset(String name, String path, double factor, boolean sync)
    Load a star dataset from a VOTable, a CSV or a FITS file.
    boolean
    load_star_dataset(String name, String path, double factor, double[] label_color, boolean sync)
    Load a star dataset from a VOTable, a CSV or a FITS file.
    boolean
    load_star_dataset(String name, String path, double factor, double[] label_color, double[] fadein, double[] fadeout, boolean sync)
    Load a star dataset from a VOTable, a CSV or a FITS file.
    boolean
    load_variable_star_dataset(String name, String path, double factor, double[] label_color, double[] fadein, double[] fadeout, boolean sync)
    Load a variable star dataset from a VOTable, CSV or FITS file.
    boolean
    Remove the dataset identified by the given name, if it exists.
    boolean
    set_dataset_highlight_all_visible(String name, boolean visible)
    Set the 'all visible' property of datasets when highlighted.
    boolean
    Set the size increase factor of this dataset when highlighted.
    void
    set_dataset_point_size_factor(String name, double multiplier)
    Set the dataset point size multiplier.
    boolean
    set_dataset_transform_matrix(String name, double[] matrix)
    Set the given 4x4 matrix (in column-major order) as the transformation matrix to apply to all the data points in the dataset identified by the given name.
    boolean
    Show (un-hide) the dataset identified by the given name, if it exists and is hidden
  • Method Details

    • get_datasets_directory

      String get_datasets_directory()
      Return the current datasets location on disk. This is stored in a setting in the configuration file, and points to the actual location where datasets are stored.

      If you want the default datasets location, use BaseModule.get_default_datasets_dir().

      Returns:
      The path to the current location used to store datasets.
    • load_dataset

      boolean load_dataset(String name, String path)
      Load a VOTable, FITS, CSV or JSON dataset file with the given name. In this version, the loading happens synchronously, so the catalog is available to Gaia Sky immediately after this call returns. The actual loading process is carried out making educated guesses about semantics using UCDs and column names. Please check the official documentation for a complete reference on what can and what can't be loaded.
      Parameters:
      name - The name of the dataset, used to identify the subsequent operations on the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot file to load.
      Returns:
      False if the dataset could not be loaded, true otherwise.
    • load_dataset

      boolean load_dataset(String name, String path, boolean sync)
      Load a VOTable, FITS, CSV or JSON dataset file with the given name. The call can be made synchronous or asynchronous.
      If sync is true, the call acts exactly like load_dataset(String, String).
      If sync is false, the loading happens in a new thread and the call returns immediately. In this case, you can use dataset_exists(String) to check whether the dataset is already loaded and available. The actual loading process is carried out making educated guesses about semantics using UCDs and column names. Please check the official documentation for a complete reference on what can and what can't be loaded.
      Parameters:
      name - The name of the dataset, used to identify the subsequent operations on the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the file to load.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_dataset

      boolean load_dataset(String name, String path, CatalogInfo.CatalogInfoSource type, DatasetOptions options, boolean sync)
      Load a VOTable, FITS, CSV or JSON dataset file with the given name. The call can be made synchronous or asynchronous.
      If sync is true, the call acts exactly like load_dataset(String, String, boolean).
      If sync is false, the loading happens in a new thread and the call returns immediately. In this case, you can use dataset_exists(String) to check whether the dataset is already loaded and available. The actual loading process is carried out making educated guesses about semantics using UCDs and column names. Please check the official documentation for a complete reference on what can and what can't be loaded. This version includes the catalog info type.
      Parameters:
      name - The name of the dataset, used to identify the subsequent operations on the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the file to load.
      type - The CatalogInfo.CatalogInfoSource object to use as the dataset type.
      options - The DatasetOptions object holding the options for this dataset.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_star_dataset

      boolean load_star_dataset(String name, String path, boolean sync)
      Load a star dataset from a VOTable, a CSV or a FITS file. The dataset does not have a label. The call can be made synchronous or asynchronous.
      If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_star_dataset

      boolean load_star_dataset(String name, String path, double factor, boolean sync)
      Load a star dataset from a VOTable, a CSV or a FITS file. The dataset does not have a label. The call can be made synchronous or asynchronous.
      If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      factor - Scaling additive factor to apply to the star magnitudes, as in appmag = appmag - magnitudeScale.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_star_dataset

      boolean load_star_dataset(String name, String path, double factor, double[] label_color, boolean sync)
      Load a star dataset from a VOTable, a CSV or a FITS file. The call can be made synchronous or asynchronous.
      If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      factor - Scaling additive factor to apply to the star magnitudes, as in appmag = appmag - magnitudeScale.
      label_color - The color of the labels, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_star_dataset

      boolean load_star_dataset(String name, String path, double factor, double[] label_color, double[] fadein, double[] fadeout, boolean sync)
      Load a star dataset from a VOTable, a CSV or a FITS file. The call can be made synchronous or asynchronous.
      If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      factor - Scaling additive factor to apply to the star magnitudes, as in appmag = appmag - magnitudeScale.
      label_color - The color of the labels, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      fadein - Two values which represent the fade in mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      fadeout - Two values which represent the fade out mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_particle_dataset

      boolean load_particle_dataset(String name, String path, double decay, double[] color, double noise, double[] label_color, double size, String ct, boolean sync)
      Load a particle dataset (point cloud) from a VOTable, a CSV or a FITS file. The call can be made synchronous or asynchronous.
      If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      decay - The profile decay of the particles as in 1 - distCentre^decay.
      color - The base color of the particles, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      noise - In [0,1], the noise to apply to the color so that each particle gets a slightly different tone. Set to 0 so that all particles get the same color.
      label_color - The color of the labels, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      size - The size of the particles in pixels.
      ct - The name of the component type to use like "Stars", "Galaxies", etc. (see ComponentTypes.ComponentType).
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_particle_dataset

      boolean load_particle_dataset(String name, String path, double decay, double[] color, double noise, double[] label_color, double size, String ct, double[] fadein, double[] fadeout, boolean sync)
      Load a particle dataset (point cloud) from a VOTable, a CSV or a FITS file. The call can be made synchronous or asynchronous.
      If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      decay - The profile decay of the particles as in 1 - distCentre^decay.
      color - The base color of the particles, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      noise - In [0,1], the noise to apply to the color so that each particle gets a slightly different tone. Set to 0 so that all particles get the same color.
      label_color - The color of the labels, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      size - The size of the particles in pixels.
      ct - The name of the component type to use like "Stars", "Galaxies", etc. (see ComponentTypes.ComponentType).
      fadein - Two values which represent the fade in mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      fadeout - Two values which represent the fade out mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_particle_dataset

      boolean load_particle_dataset(String name, String path, double decay, double[] color, double noise, double[] label_color, double size, double[] size_limits, String ct, double[] fadein, double[] fadeout, boolean sync)
      Load a particle dataset (point cloud) from a VOTable, a CSV or a FITS file. The call can be made synchronous or asynchronous.
      If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      decay - The profile decay of the particles as in 1 - distCentre^decay.
      color - The base color of the particles, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      noise - In [0,1], the noise to apply to the color so that each particle gets a slightly different tone. Set to 0 so that all particles get the same color.
      label_color - The color of the labels, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      size - The size of the particles in pixels.
      size_limits - The minimum and maximum size of the particles in pixels.
      ct - The name of the component type to use like "Stars", "Galaxies", etc. (see ComponentTypes.ComponentType).
      fadein - Two values which represent the fade in mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      fadeout - Two values which represent the fade out mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_star_cluster_dataset

      boolean load_star_cluster_dataset(String name, String path, double[] color, double[] fadein, double[] fadeout, boolean sync)
      Load a star cluster dataset from a CSV, VOTable or FITS file. The file needs the columns with the following names: name, ra, dec, dist, pmra, pmdec, radius, radvel. Uses the same color for clusters and labels. The call can be made synchronous or asynchronous. If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      color - The base color of the particles and labels, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      fadein - Two values which represent the fade in mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      fadeout - Two values which represent the fade out mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_star_cluster_dataset

      boolean load_star_cluster_dataset(String name, String path, double[] color, double[] label_color, double[] fadein, double[] fadeout, boolean sync)
      Load a star cluster dataset from a CSV, VOTable or FITS file. The file needs the columns with the following names: name, ra, dec, dist, pmra, pmdec, radius, radvel. The call can be made synchronous or asynchronous. If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      color - The base color of the particles, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      label_color - The color of the labels, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      fadein - Two values which represent the fade in mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      fadeout - Two values which represent the fade out mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_star_cluster_dataset

      boolean load_star_cluster_dataset(String name, String path, double[] color, String ct, double[] fadein, double[] fadeout, boolean sync)
      Load a star cluster dataset from a CSV, VOTable or FITS file. The file needs the columns with the following names: name, ra, dec, dist, pmra, pmdec, radius, radvel. Uses the same color for clusters and labels. The call can be made synchronous or asynchronous. If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      color - The base color of the particles and labels, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      ct - The name of the component type to use (see ComponentTypes.ComponentType).
      fadein - Two values which represent the fade in mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      fadeout - Two values which represent the fade out mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_star_cluster_dataset

      boolean load_star_cluster_dataset(String name, String path, double[] color, double[] label_color, String ct, double[] fadein, double[] fadeout, boolean sync)
      Load a star cluster dataset from a CSV, VOTable or FITS file. The file needs the columns with the following names: name, ra, dec, dist, pmra, pmdec, radius, radvel. The call can be made synchronous or asynchronous. If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      color - The base color of the particles and labels, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      label_color - The color of the labels, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      ct - The name of the component type to use (see ComponentTypes.ComponentType).
      fadein - Two values which represent the fade in mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      fadeout - Two values which represent the fade out mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_variable_star_dataset

      boolean load_variable_star_dataset(String name, String path, double factor, double[] label_color, double[] fadein, double[] fadeout, boolean sync)
      Load a variable star dataset from a VOTable, CSV or FITS file. The variable star table must have the following columns representing the light curve:
      • g_transit_time: list of times as Julian days since J2010 for each of the magnitudes
      • g_transit_mag: list of magnitudes corresponding to the times in g_transit_times
      • pf: the period in days
      The call can be made synchronous or asynchronous.
      If sync is true, the call waits until the dataset is loaded and then returns. If sync is false, the loading happens in a new thread and the call returns immediately. It includes some parameters to apply to the new star group.
      Parameters:
      name - The name of the dataset.
      path - Absolute path (or relative to the working path of Gaia Sky) to the .vot, .csv or .fits file to load.
      factor - Scaling additive factor to apply to the magnitudes in the light curve, as in appmag = appmag - magnitudeScale.
      label_color - The color of the labels, as an array of RGBA (red, green, blue, alpha) values in [0,1].
      fadein - Two values which represent the fade in mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      fadeout - Two values which represent the fade out mapping distances (in parsecs, as distance from camera to the Sun) of this dataset. Set to null to disable.
      sync - Whether the load must happen synchronously or asynchronously.
      Returns:
      False if the dataset could not be loaded (sync mode). True if it could not be loaded (sync mode), or sync is false.
    • load_json_dataset

      boolean load_json_dataset(String name, String path)
      Load a Gaia Sky JSON dataset file asynchronously. The call returns immediately, and the dataset becomes available when it finished loading. The Gaia Sky JSON data format is described here.
      Parameters:
      name - The name of the dataset.
      path - The absolute path, or the path in the data directory, of the dataset file.
      Returns:
      False if the dataset could not be loaded. True otherwise.
    • load_json_dataset

      boolean load_json_dataset(String name, String path, boolean sync)
      Load a Gaia Sky JSON dataset file in a synchronous or asynchronous manner. The Gaia Sky JSON data format is described here.
      Parameters:
      name - The name of the dataset.
      path - The absolute path, or the path in the data directory, of the dataset file.
      sync - If true, the call does not return until the dataset is loaded and available in Gaia Sky.
      Returns:
      False if the dataset could not be loaded. True otherwise.
    • load_json_dataset

      boolean load_json_dataset(String name, String path, boolean select, boolean sync)
      Load a Gaia Sky JSON dataset file in a synchronous or asynchronous manner. The Gaia Sky JSON data format is described here.
      Parameters:
      name - The name of the dataset.
      path - The absolute path, or the path in the data directory, of the dataset file.
      select - If true, focus the first object in the dataset after loading.
      sync - If true, the call does not return until the dataset is loaded and available in Gaia Sky.
      Returns:
      False if the dataset could not be loaded. True otherwise.
    • remove_dataset

      boolean remove_dataset(String name)
      Remove the dataset identified by the given name, if it exists.
      Parameters:
      name - The name of the dataset to remove.
      Returns:
      False if the dataset could not be found.
    • hide_dataset

      boolean hide_dataset(String name)
      Hide the dataset identified by the given name, if it exists and is not hidden.
      Parameters:
      name - The name of the dataset to hide.
      Returns:
      False if the dataset could not be found.
    • list_datasets

      List<String> list_datasets()
      Return the names of all datasets currently loaded.
      Returns:
      A list with all the names of the loaded datasets.
    • dataset_exists

      boolean dataset_exists(String name)
      Check whether the dataset identified by the given name is loaded
      Parameters:
      name - The name of the dataset to query.
      Returns:
      True if the dataset is loaded, false otherwise.
    • show_dataset

      boolean show_dataset(String name)
      Show (un-hide) the dataset identified by the given name, if it exists and is hidden
      Parameters:
      name - The name of the dataset to show.
      Returns:
      False if the dataset could not be found.
    • set_dataset_transform_matrix

      boolean set_dataset_transform_matrix(String name, double[] matrix)
      Set the given 4x4 matrix (in column-major order) as the transformation matrix to apply to all the data points in the dataset identified by the given name.
      Parameters:
      name - The name of the dataset.
      matrix - The 16 values of the 4x4 transformation matrix in column-major order.
      Returns:
      True if the dataset was found and the transformation matrix could be applied. False otherwise.
    • clear_dataset_transform_matrix

      boolean clear_dataset_transform_matrix(String name)
      Clear the transformation matrix (if any) in the dataset identified by the given name.
      Parameters:
      name - The name of the dataset.
      Returns:
      True if the dataset was found and the transformations cleared.
    • highlight_dataset

      boolean highlight_dataset(String name, int color_idx, boolean highlight)
      Enable or disable the dataset highlight, using a plain color given by the color index:
      • 0 - blue
      • 1 - red
      • 2 - yellow
      • 3 - green
      • 4 - pink
      • 5 - orange
      • 6 - purple
      • 7 - brown
      • 8 - magenta
      Parameters:
      name - The dataset name.
      color_idx - Color index in [0,8].
      highlight - Whether to highlight or not.
      Returns:
      False if the dataset could not be found.
    • highlight_dataset

      boolean highlight_dataset(String name, boolean highlight)
      Enable or disable the dataset highlight using a plain color chosen by the system.
      Parameters:
      name - The dataset name.
      highlight - State.
      Returns:
      False if the dataset could not be found.
    • highlight_dataset

      boolean highlight_dataset(String name, float[] color, boolean highlight)
      Enable or disable the dataset highlight, using a given plain color.
      Parameters:
      name - The dataset name.
      color - RGBA color as an array with 4 floats, each in [0,1].
      highlight - State.
      Returns:
      False if the dataset could not be found.
    • highlight_dataset

      boolean highlight_dataset(String name, String attr_name, String colmap, double min, double max, boolean highlight)
      Enable or disable the dataset highlight, using the given color map on the given attribute with the given maximum and minimum mapping values.
      Parameters:
      name - The dataset name.
      attr_name - The attribute name. You can use basic attributes (please mind the case!):
      • RA
      • DEC
      • Distance
      • GalLatitude
      • GalLongitude
      • EclLatitude
      • EclLongitude
      Or star-only attributes (if your dataset contains stars, mind the case!):
      • Mualpha
      • Mudelta
      • Radvel
      • Absmag
      • Appmag
      Or even extra attributes (if you loaded the dataset yourself), matching by column name.
      colmap - The color map to use, in ["reds"|"greens"|"blues"|"rainbow18"|"rainbow"|"seismic"|"carnation"|"hotmeal"|"cool"].
      min - The minimum mapping value.
      max - The maximum mapping value.
      highlight - State.
      Returns:
      False if the dataset could not be found.
    • set_dataset_highlight_size_factor

      boolean set_dataset_highlight_size_factor(String name, float factor)
      Set the size increase factor of this dataset when highlighted.
      Parameters:
      name - The dataset name.
      factor - The size factor to apply to the particles when highlighted, must be in [Constants.MIN_DATASET_SIZE_FACTOR, Constants.MAX_DATASET_SIZE_FACTOR].
      Returns:
      False if the dataset could not be found.
    • set_dataset_highlight_all_visible

      boolean set_dataset_highlight_all_visible(String name, boolean visible)
      Set the 'all visible' property of datasets when highlighted. If set to true, all stars in the dataset have an increased minimum opacity when highlighted, so that they are all visible. Otherwise, stars retain their minimum opacity and base brightness.
      Parameters:
      name - The dataset name.
      visible - Whether all stars in the dataset should be visible when highlighted or not.
      Returns:
      False if the dataset could not be found.
    • set_dataset_point_size_factor

      void set_dataset_point_size_factor(String name, double multiplier)
      Set the dataset point size multiplier.
      Parameters:
      name - The dataset name.
      multiplier - The multiplier, as a positive floating point number.