Skip to content

Plotting suggestions #17

@jlillo

Description

@jlillo

Great tool! A couple of suggestions for the plotting tools:

  • It would be awesome if the phase_plot could plot the phase-folded RV curves for signals sorted by the number of samples of the corresponding periodicity instead of being sorted by RV semi-amplitude as it is now.
  • It would be great to add an option for the plot_posterior_period function to include the periods of the most prominent peaks. Currently, the option show_peaks is only available if kde=True. It is quite simple to implement it for the other case. simply adding this:
        if show_peaks and find_peaks:
            peaks, _ = find_peaks(y, prominence=5*np.nanmedian(y))
            for peak in peaks:
                s = r'P$\simeq$%.2f' % xx[peak]
                ax.text(xx[peak], y[peak], s, ha='left')

Note that here I changed to the default prominence=0.1 to a value dependent on the "noise floor" of the samples. But of course feel free to modify this if you are interested in adding this to the code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions