Analyze

class lisacattools.analyze.AbstractLisaAnalyze[source]

Abstract Object to link the two implementation and to share some method.

class lisacattools.analyze.CatalogAnalysis(catalog: GWCatalog, save_img_dir=None)[source]

Handle the analysis of one catalog.

property catalog

Catalog.

Getter:

Returns the catalog of this analysis

Setter:

Sets the catalog.

Type:

GWCatalog

plot_corners(source_name, params, *args, **kwargs) NoReturn[source]

Some corners plots.

plot_individual_sources() NoReturn[source]

Plot the indivual sources.

plot_mbh_mergers_history() NoReturn[source]

Plot the history of observed mergers.

plot_skymap(source, nside, system: FrameEnum = FrameEnum.ECLIPTIC) NoReturn[source]

Plot skymap.

property save_img_dir

Save image directory for plot.

Getter:

Returns the directory where plots are saved

Setter:

Sets the directory where plots are saved.

Type:

str

class lisacattools.analyze.HistoryAnalysis(catalogs: GWCatalogs, save_img_dir=None)[source]

Analyse a particular source to see how it’s parameter estimates improve over time

property catalogs

Catalogs.

Getter:

Returns the catalogs of this analysis

Setter:

Sets the catalogs.

Type:

GWCatalogs

plot_parameter_time_evolution(df: DataFrame, time_parameter: str, parameter: str, *args, **kwargs) NoReturn[source]

Plot the parameter that evolves over time.

Note: extra parameter can be configured: - plot_type, default : scatter - grid, default : True - marker, default : ‘s’ - linestyle, default : ‘-’ - yscale, default : log - title, default : Evolution

Parameters:
  • df (pd.DataFrame) – data

  • time_parameter (str) – time parameter in the data

  • parameter (str) – parameter to plot over the time

plot_parameter_time_evolution_from_source(catalog_name: str, source_name: str, time_parameter: str, parameter: str, *args, **kwargs) NoReturn[source]

Plot the parameter that evolves over time for a given source starting from a catalog.

Note: extra parameter can be configured: - plot_type, default : scatter - grid, default : True - marker, default : ‘s’ - linestyle, default : ‘-’ - yscale, default : log - title, default : Evolution

Parameters:
  • df (pd.DataFrame) – data

  • catalog_name (str) – Start the evolution from the oldest one

  • one (until that) –

  • source_name (str) – source name to follow up

  • time_parameter (str) – time parameter in the data

  • parameter (str) – parameter to plot over the time

plot_parameters_correlation_evolution(allEpochs: DataFrame, wks: List, params: List, colors: List, *args, **kwargs) NoReturn[source]

To dig into how parameter correlations might change over time, we can look at a time-evolving corner plot

Parameters:
  • allEpochs (pd.DataFrame) – observation of a source at different

  • epochs

  • wks (List) – weeks to plot

  • params (List) – parameters to plot

  • colors (List) – color according the weeks

plot_parameters_evolution(all_epochs: DataFrame, params: List, scales: List, *args, **kwargs) NoReturn[source]

Show evolution over many different epochs.

Parameters:
  • all_epochs (pd.DataFrame) – observation of a source at

  • epochs (different) –

  • params (List) – list of parameters to plot

  • scales (List) – Scale for each plot

plot_skymap_evolution(nside: int, allEpochs: DataFrame, wks: List, system: FrameEnum = FrameEnum.GALACTIC, *args, **kwargs) NoReturn[source]

Plot the skymap evolution

Parameters:
  • nside (int) – parameter for healpix related to the number of cells

  • allEpochs (pd.DataFrame) – observation of a source at different

  • epochs

  • wks (List) – weeks to plot

  • system (FrameEnum, optional) – coordinate reference frame. Defaults

  • 'FrameEnum.GALACTIC'. (to) –

property save_img_dir

Save image directory for plot.

Getter:

Returns the directory where plots are saved

Setter:

Sets the directory where plots are saved.

Type:

str

class lisacattools.analyze.LisaAnalyse[source]

Factory to create an analysis for a catalog or a time-evolution of the catalog.