Skip to content
This repository has been archived by the owner on Jul 18, 2023. It is now read-only.

Explain .round() #22

Open
tomvannuenen opened this issue Oct 25, 2022 · 0 comments
Open

Explain .round() #22

tomvannuenen opened this issue Oct 25, 2022 · 0 comments

Comments

@tomvannuenen
Copy link

Using .round() in Manipulating Columns needs to be explained. If we don’t use it, we will not get to a full integer and then calling int() will truncate. Compare ((unemployment['year_month'] - unemployment['year']) * 100).astype(int) and ((unemployment['year_month'] - unemployment['year']) * 100).round(0).astype(int) - the first starts at 0, second starts at 1

@tomvannuenen tomvannuenen changed the title Explain .round() Explain .round() Oct 25, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant