plotly / plotly.py

The interactive graphing library for Python :sparkles: This project now includes Plotly Express!
https://plotly.com/python/
MIT License
16.04k stars 2.54k forks source link

parcoords documentation mentions non-existent property #1298

Closed skylogic004 closed 5 years ago

skylogic004 commented 5 years ago

In the documentation for the parcoords chart, under the dimensions section, in tickvals and ticktext it says:

Only has an effect if tickmode is set to "array".

However, I've read the entire documentation for parcoords and there is no tickmode property (except in the colorbar section which is unrelated).

So, if I'm understanding correctly, then the documentation is wrong. Probably a copy+paste bug where someone forgot to remove the reference to tickmode?

p.s. is this the right place to report documentation issues? or only code issues? p.p.s. it's also possible that this is a code issue, meaning that the tickmode was supposed to exist in the code but doesn't.

jonmmease commented 5 years ago

Thanks for the report @skylogic004! Reporting docs issues here is fine, and then we can sort out the source of the error. In this case, it will need to be addressed in plotly.js, because that's where the master schema for all of the figure properties is maintained.

I've opened an issue over there at https://github.com/plotly/plotly.js/issues/3313. I'm going to close this issue since plotly.py will automatically get the documentation updates once they are implemented and released in plotly.js. Thanks again for taking the time to bring this up!

JamesPHoughton commented 5 years ago

There still seems to be some difference between what is listed in the docs and what is available in the API. For example, the docs suggest a way to change properties of the coordinate labels:

However, using these results in an error:

ValueError: Invalid property specified for object of type plotly.graph_objs.Parcoords: 'labelangle'

    Valid properties:
        customdata
            ...
        customdatasrc
            ...
        dimensions
            ...
        dimensiondefaults
            ...
        domain
            ...
        ids
            ...
        idssrc
            ...
        labelfont
            ...
        line
            ...
        meta
            ...
        metasrc
            ...
        name
            ...
        rangefont
            ...
        stream
            ...
        tickfont
            ...
        uid
            ...
        uirevision
            ...
        visible
            ...

It would be quite nice to actually have these features, so this may not be a docstring error, but a problem with exposing the method.

jonmmease commented 5 years ago

Hi @JamesPHoughton,

These properties are coming in plotly.py 4.1.0. They were just released in Plotly.js 1.49.0 a couple weeks ago. I guess the docs got ahead of us!

You can install version 4.1.0rc1 (released yesterday) if you'd like to try them out now.

JamesPHoughton commented 5 years ago

You just made my day. =)

nicolaskruchten commented 5 years ago

We're working on a way of locking the Py docs and Py versions more tightly together so this kind of thing doesn't happen any more... sorry for the confusion!