Skip to content
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

recommendation: change cellsize to cellarea #747

Open
alex-s-gardner opened this issue Sep 19, 2024 · 3 comments
Open

recommendation: change cellsize to cellarea #747

alex-s-gardner opened this issue Sep 19, 2024 · 3 comments

Comments

@alex-s-gardner
Copy link
Contributor

alex-s-gardner commented Sep 19, 2024

cellsize is a bit ambiguous, cell area is not

Also, it could be helpful if cellsize() accepted a kwarg of "unit" if the user wanted a unit other than km^2 returned.

Given that projected units are always in meters, and meter is si units, I wonder if returning meters^2 by default would be a better choice in the long run.

@rafaqz
Copy link
Owner

rafaqz commented Sep 19, 2024

I'll add unitful support soon for CF as well, so that can happen at the same time.

For cellarea PR and deprecated cellsize?

@tiemvanderdeure ?

@tiemvanderdeure
Copy link
Contributor

I have no strong feelings about this one. The name cellsize comes from the function in terra in R with the same name: https://rdrr.io/cran/terra/man/cellSize.html.

Changing to meter units would be breaking but it would make sense to do it at the same time as a name change.

@rafaqz
Copy link
Owner

rafaqz commented Sep 19, 2024

I think we will have a units keyword for opt-in units wherever they're used, false by default.

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

No branches or pull requests

3 participants