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

Request: modify patches() to output clumps of cells wth the same value #1632

Open
aloboa opened this issue Oct 26, 2024 · 2 comments
Open

Request: modify patches() to output clumps of cells wth the same value #1632

aloboa opened this issue Oct 26, 2024 · 2 comments

Comments

@aloboa
Copy link

aloboa commented Oct 26, 2024

It would be helpful if the output of patches() were clumps of cells with the same value, regardless
the neighbors are NA or not.

input:
55555555555
55555555555
55444554455
55444554445
54444454455
55555555555
output
11111111111
11111111111
11222113311
11222113331
12222213311
11111111111

(see end of #576)

The desired output can be (inefficiently) obtained by running the current patches() within a loop for all unique(values(input)).

@Nowosad
Copy link
Contributor

Nowosad commented Oct 26, 2024

Same as #495?

@aloboa
Copy link
Author

aloboa commented Oct 27, 2024

Same as #495?

Yes, and it is very similar to #576 too. I opened a new one to make a more appropriate title and specify it as a Feature request, not a bug.

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

2 participants