Giter Club home page Giter Club logo

Comments (6)

castillohair avatar castillohair commented on July 24, 2024 4

Hi,

I have implemented log-scaled axes.

import numpy as np
import matplotlib.pyplot as plt
import corner

cov = np.array([[ 0.1, 0.04, 0.06,],
                [0.04,  0.1, 0.06,],
                [0.06, 0.06,  0.1]])
mu  = np.array([1, 1.5, 2])

x = 10**(np.random.multivariate_normal(mu, cov, size=10000))
corner.corner(x, axes_scale='log')

log_test

If there's interest, I'd be willing to tidy up the code, work on the tests, and submit a pull request. Please let me know if that is the case.

from corner.py.

ZardozSav avatar ZardozSav commented on July 24, 2024 1

Hi !

Is that implemented yet ? I am also interested to use logscale for the axis .
If we provide bin edges and not just only the number of bins, it should work right ?

from corner.py.

dfm avatar dfm commented on July 24, 2024

This isn't possible currently. Your best bet is to take the log of your samples and label the axis log(x).

from corner.py.

NeutralKaon avatar NeutralKaon commented on July 24, 2024

@castillohair -- there's definitely interest from me; please do post a gist or a diff at least!

Having had a very brief look at this, it is a bit of work: you can't just change the axes mode as the surface and contours drawn are wrong. Your help would be rather welcome!

from corner.py.

jtlz2 avatar jtlz2 commented on July 24, 2024

@castillohair Did you ever get to submitting a PR? Thanks! cc @dfm

from corner.py.

castillohair avatar castillohair commented on July 24, 2024

I just submitted a pull request with the code I made a while ago. It may need some tidying up to work with the last version but I'm going to wait for comments from @dfm before dedicating time to it. In the meantime, feel free to use it or my branch at https://github.com/castillohair/corner.py/tree/log-scale.

from corner.py.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.