aloisdg
Any news about adding a transpose function to the standard lib? It was discussed on the mailing list in 2021, but nothing since.
Transposing lists are a quite common operation and people often talk about it online like on this forum. From working with CSV, to doing the advent of code, transposing matrix is everywhere.
- The impact on the eco-system would be limited. This is just another function.
- The impact on learning would be good since this function is quite common in other language. Even VBA has it.
- This suggestion is easily implemented with the state of Elixir
- Some people wont need it but others will be grateful to find it.
cheers,
Trending in Discussions
As the title says, please share what you’ve been up to with Elixir. Whether that’s been learning it, looking into it, making stuff with i...
New
The obligatory hello world thread!
Who are you and where are you from? :stuck_out_tongue:
New
I want to open this thread for you all to discuss and help those who really like Ash but are still hesitant to use it in a real project. ...
New
I was working on an Ecto migration and I needed a timestamp. So, for the nth time, I looked up the different data types for timestamps, a...
New
Fly’s CEO posted this recently - Turn And Face The Strange · The Fly Blog
It says that Fly is going all-in on sprites, which is a worry ...
New
We’re evaluating API mocking tools for OpenAPI-based projects and would love to hear what other teams are using.
We’re particularly inte...
New
Is there a word for the ~> symbol used in Version strings?
Do you also just call it a Squiggle Arrow™ ?!
New
Other Trending Topics
Hobbes is a low-level distributed database for the Elixir programming language.
Hobbes provides a simple, safe, and scalable storage lay...
New
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
ExRatatui lets you cook up rich terminal UIs in Elixir, powered by Rust’s ratatui via Rustler NIFs. Build interactive terminal applicatio...
New
Hello everyone. After busy few months I am happy to announce v0.1.0 of Emerge & Solve.
They are GUI (Emerge) and State management (S...
New
Corex is an accessible, unstyled UI component library for Phoenix that integrates Zag.js state machines using Vanilla JavaScript and Live...
New
There are three potential reasons for members of this forum to have a look at https://vutuv.de
You are tired or annoyed of LinkedIn.
Yo...
New
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #blog-post
- #ai
- #phoenix_html
- #iex
- #elixirconf-us
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #hex
- #security
- #metaprogramming











Showing Posts 1 to 8- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
benwilson512
There is a transpose function in Explorer which I think is a better fit than the standard library. Lists of lists are just flat not an efficient structure on which to do matrix operations, and I don’t think it makes sense to build a set of functions around using them for that purpose.
aloisdg
So we need an external dependence to do something as trivial as rotate a list of list? I am not asking to handle matrix in the standard library, I am asking for something for List and Enum.
benwilson512
Serious question: when are you rotating a list of lists in Elixir? Advent of code and other puzzles don’t count.
Explorer and Nx were created by the creators of elixir explicitly to do number crunching operations in the language. Given the extra dependencies involved and the relatively specialized area of work for those operations within the general use cases of the language.
LostKobrakai
Isn‘t
Enum.zip_with(nested, & &1)what you‘re looking for?aloisdg
Yes it is working. Note that what I am looking for is not quite an implementation of transpose but a way to add transpose to the library. This goal is not have to write it each time
aloisdg
Last time it was to handle data send by a client in day job. It was not in Elixir. So the answer to " Any update on a transpose function?" would be “none because not enough people ask for it” right?
dimitarvp
I don’t speak for Ben but IMO the answer would be more along the lines of: “We deem this a more specialized functionality and as such we will not put it in the standard library and into a dedicated number-crunching library instead”.
aloisdg
alright. thank you