| ▲ | culebron21 5 hours ago | |||||||
This was underwhelming. I work with Python and Pandas, and I can show examples of much clumsier workflows I run into. The most often, you get dataframe[(dataframe.column1 == something) & ~dataframe.column2.isna()] constucts, which show that python syntax falls short here, and isn't suitable for such manipulations. Unfortunately, there's no alternative, and I don't see R as much easier, there are plenty of ugly things as well there. There's Julia -- it has serious drawbacks, like slow cold start if you launch a Julia script from the shell, which makes it unsuitable for CLI workflows. Otherwise you have to switch to compiled languages, with their tradeoffs. | ||||||||
| ▲ | markkitti 2 hours ago | parent [-] | |||||||
> Unfortunately, there's no alternative, and I don't see R as much easier, there are plenty of ugly things as well there. Have you tried Polars? It really discourages the inefficient creation of intermediate boolean arrays such as in the code that you are showing. > There's Julia -- it has serious drawbacks, like slow cold start if you launch a Julia script from the shell, which makes it unsuitable for CLI workflows. Julia has gotten significantly better over time with regard to startup, especially with regard to plotting. There is definitely a preference for REPL or notebook based development to spread the costs of compilation over many executions. Compilation is increasingly modular with package based precompilation as well as ahead-of-time compilation modes. I do appreciate that typical compilation is an implicit step making the workflow much more similar to a scripting language than a traditionally compiled language. I also do appreciate that traditional ahead-of-time static compilation to binary executable is also available now for deployment. After a day of development in R or Python, I usually start regretting that I am not using Julia because I know yesterday's code could be executing much faster if I did. The question really becomes do I want to pay with time today or over the lifetime of the project. | ||||||||
| ||||||||