enable arbitrary formatting on x-axis and y-axis tick labels
Personne n'a encore pris cette issue.
- Langage dominant
- Python
- Étoiles
- 18.8k
- Forks
- 2.8k
- Merge moyen
- 16 h 26 min
- PR mergées (30 j)
- 21
Description
Thanks for the awesome work on this project! It is incredibly useful!
I have a feature request. I work for a hedge fund and we want our plotly graphs to follow a standardized format. I am having a hard time through writing a generic formatting function that formats the x-axis and y-axis tick values.
For instance, if you wanted to set the tick axis to be bold and include a "x" at the end, you would need to do something like:
fig.update_layout(
yaxis = dict(
tickmode = 'array',
tickvals = [1, 2, 3],
ticktext = ["<b>1x</b>", "<b>2x</b>", "<b>3x</b>"]
)
)
Which is pretty inconvenient because you have to specify the tickvals every time you want to do this.
So I was thinking that it could be a good idea to add something like:
fig.update_xaxis(tick_text_formatter=<function that formats a tick value>)
Thoughts?
Again, thanks for the awesome work!
Guide de contribution
Ouvrir le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Piste de recherche
Commencez par les points d’entrée publics fig.update_layout et fig.update_xaxis, puis suivez la manière dont sont représentées les étiquettes des graduations des axes x et y. Définissez le comportement et l’API du formateur, et réfléchissez à la manière dont les tests devraient vérifier un formatage arbitraire sans nécessiter de tickvals et ticktext manuels.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- plotly, python
- Domaine
- data-visualization
- Type d'issue
- Fonctionnalité
- Difficulté
- 5/5
- Temps estimé
- Plus d'une semaine
- Activité
- Active
- Clarté
- À clarifier
- Accessibilité débutants
- 35/100