How do I show data in codeacadmy's way?

Hi while doing pandas I was wondering if there is any way to show the output in the way codeacdemy is showing it?

i.e
on my own computer:

   Product ID   Description  Cost to Manufacture  Price  Margin
0           1  3-inch screw                  0.5   0.75    0.25
1           2   2-inch nail                  0.1   0.25    0.15
2           3        hammer                  3.0   5.50    2.50
3           4   screwdriver                  2.5   3.00    0.50

and on codeacadmy’s online web browser thing
Screenshot 2024-02-12 at 3.55.16 PM

I assume that’s a Jupyter Notebook output/display. Is there a lesson in your course on Jupyter Notebook?

ex:

There’s also a styler class you can use in Pandas:
https://pandas.pydata.org/docs/user_guide/style.html

I am using PyCharm an IDE

Did you check their documentation?

If you have the pro version, you can integrate Jupyter Notebooks into it. Otherwise, read up on the Pandas link I posted above or, use Jupyter or Google Colab.

Yeah, I am pretty sure it’s not in their documentation, but I will check the pandas documentation

The default output looks like this:
Screenshot 2024-02-14 at 3.35.43 PM

I want to make it look better, just explaining what I mean

Then use Jupyter Notebook or Google Colab instead.

Colab has a cool built in feature where you can take the df output and make an interactive data table by clicking on a button.

1 Like

Alright, I got it thanks! :+1: