-
-
Notifications
You must be signed in to change notification settings - Fork 84
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
converting pairwise values into a matrix or semi-matrix #91
Comments
This is currently what a similar tool to
|
I think this case is too special, I mean, maybe there are very few people needing this. And since |
I don't think the use case is too unusual. tidyr provides |
I had use cases for this as well, currently using datamash instead, but it
would be nice to have it in csvtk for easier portability.
…On Fri, Dec 30, 2022, 12:33 Christian G. Warden ***@***.***> wrote:
I don't think the use case is too unusual. tidyr provides spread as the
inverse of gather (now pivot_longer and pivot_wider). The pivot
documentation <https://tidyr.tidyverse.org/articles/pivot.html> provides
example use cases.
—
Reply to this email directly, view it on GitHub
<#91 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABGSN6QT2Z74UPHV2DPXG3WP3JDBANCNFSM4I72RQLQ>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Implemented: Your data
Another example: Shuffled columns:
data -> gather/longer -> spread/wider. Note that the orders of both rows and columns are kept :)
|
There may already be a solution to this with a combination of
summary
orgather
orcollapse
but here is a feature request I find myself wanting to do every once in a while:https://stackoverflow.com/questions/22492767/converting-pairwise-distances-into-a-distance-matrix-in-r
Take a list of pairwise distances and convert into a matrix:
E.g. below:
The text was updated successfully, but these errors were encountered: