lpsinger / ligo.skymap

Localization of gravitational-wave transients. Mirror of https://git.ligo.org/lscsoft/ligo.skymap
22 stars 18 forks source link

Add marker options to ligo-skymap-plot. #5

Closed Janna112358 closed 2 years ago

Janna112358 commented 4 years ago

The following options are added that specify shape, color, edge color and size of the marker used with the --radec option that already existed: --marker to specify the symbol --marker-color for the color --marker-ecolor for the edge color (outside line of the marker) --marker-size for the size

Defaults are implemented so that the behaviour does not change when NOT specifying any of these new options. I.e. by default, --radec plots a size 10 star ('*') marker in white with a black outline.

Working on: adding options and code to plot locations of PTA pulsars using an input text file with specified locations and pulsar noise levels.

Janna112358 commented 4 years ago

Added options to mark the pulsars from a Pulsar Timing Array.

The following options are added in a separate PTA group in the parser (so that they are displayed separately in the --help message): --pta-file: use a file pulsars.csv to specify ra, dec locations of the PTA pulsars and (optionally) a third column with pulsar noise rms to scale the markers with --pta-size: Optional to only use the first "n" pulsars from the file --pta-marker: specify the marker symbol (default '*') --pta-color: the marker color (default white) --pta-ecolor: the marker edge color (default black) --pta-fix-marker-size: Do not scale the markers with noise rms, instead use a single size value for all.

The --pta-file needs to be a csv file with the first two columns being Ra and Dec (in degrees). There either needs to be a third column with the noise rms level (in seconds) of each pulsar, OR the option --pta-fix-marker-size needs to be specified. In the first case, the marker size of each pulsar is scaled with the rms level as: 10 * (rms / 1.e-7)**(-0.4). This is purely an empirical scaling I found looks good for typical rms noise values. Pulsars with lower noise rms ("better" pulsars) are displayed bigger. One could easily add another option for an overall size scaling by replacing the 10 in this relation.