dfm / dfm/corner.py

Add option for rotated view of last marginalisation

Open
#246 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
576
Forks
234
PR merge metrics
No merged PRs in 30d

Description

Add an option for displaying the last marginalisation (lower right 1D plot) with the x-axis vertically instead of horizontally. The rationale behind this is that the distribution matches the 2D plot better, especially in the case of only two dimensions: In this case and with such an option, corner would produce the typical plot of a 2D distribution in the center with marginalised distributions on the sides, like shown here.

To implement this it would be necessary to rotate the plot clockwise by 90 degrees (and potentially invert the x-axis?). This could be achieved with ax.hist(x, orientation='vertical').

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the code that creates the lower-right 1D marginalisation plot and inspect how its ax.hist call is configured. Add an option for the rotated view, including the required axis orientation or inversion, and verify that the resulting plot aligns with the central 2D distribution as described.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
data-visualization
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.