Skip to content

DOC: Mention styler in the to_excel documentation #48019

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
datapythonista opened this issue Aug 10, 2022 · 11 comments · Fixed by #48104
Closed

DOC: Mention styler in the to_excel documentation #48019

datapythonista opened this issue Aug 10, 2022 · 11 comments · Fixed by #48104
Labels

Comments

@datapythonista
Copy link
Member

xref #47525

In our DataFrame.to_excel documentation we don't have any mention to Styler.to_excel which is very relevant.

Users checking the documentation on how to export a DataFrame to Excel should be aware that they can use the Styler to format the exported file. Personally I'd add the class to See Also, and I'd add a very short example at the end of our examples, with a link to the Styler.to_excel page. I think that would be good for users who may be interested in that feature. But other ideas also welcome.

@rhshadrach
Copy link
Member

I'm +1 on See Also and even an explicit note on when the Styler should be used (no surprise: adding styles to Excel output), but I don't think we should have examples of method A in the API docs of method B, even if they are closely related.

@Nikhil-Mudgal
Copy link

Hi is there anyway in which I can help with docs creation. I am new to open source and want to get started with a good beginner issue.

@datapythonista
Copy link
Member Author

This is a quite simple issue to work on if you're new to contributing. Not much work to do here, so you can focus on learning. You should check the contributing section in the docs to know where to start.

@Nikhil-Mudgal
Copy link

Ok thanks @datapythonista.

@FrnRmn
Copy link
Contributor

FrnRmn commented Aug 13, 2022

Hello there! I was trying to set everything up to try to give my first contribution as well but come here too late :)
Can I still ask if I was in the right direction with the current issue? Just for practice.

In case Nikhil-Mudgal doesn't want to read

Is it all about modifying a single line of the to_excel() docstring in the generic.py file?

image
This is what I see when I build the doc function with Sphinx. However, hyperlinks are not working there. Is it normal or I am not considering something else?

ps: yep, forgot a space

@rhshadrach
Copy link
Member

@FrnRmn - you're definitely on the right track here! The links should work, and for this issue we want to mention Styler.to_excel and not just Styler.

@FrnRmn
Copy link
Contributor

FrnRmn commented Aug 14, 2022

Thank you for the feedback.
When you say "the links should work" do you mean all the links that were already there?
For example in the DataFrame.to_latex See Also section the Styler.to_latex element has not an internal reference link. Is it normal or there is a problem also in this other doc?

@datapythonista
Copy link
Member Author

Thanks for the heads up @FrnRmn. It's not expected that the Styler.to_latex link in https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_latex.html is broken. Do you mind creating an issue for it please? Links should work in the changes you did, and feel free to open a PR when you've got them ready.

@FrnRmn
Copy link
Contributor

FrnRmn commented Aug 15, 2022

#48089 I hope this is done correctly

@samrao1997
Copy link
Contributor

@FrnRmn Hey fixed #48089, I can do this issue too if you would like?

@FrnRmn
Copy link
Contributor

FrnRmn commented Aug 16, 2022

@samrao1997 Hi, I have just seen your solution. I'll try your way and if I can't make it I'll tell you. Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants