Comment by 3eb7988a1663
4 days ago
Pardon? Less silent errors? R has quite a few foot guns around permissively parsing user intention. Which does make it handy for exploratory analysis, but a lot more fragile when you want production code.
Just a simple one that can get you, R is 1-indexed. Yet if you have a vector, accessing myvec[0] is not an error. Alternatively, if you had say, a vector length of 3 and do myvec[10] that gets NA (an otherwise legal value). Or you could make an assignment past the end of the vector myvec[15] <- 3.14 , which will silently extend the array, inserting NAs
All languages have things like that, but from my experience developing a number of widely used scientific software packages for both Python and R, those sort of bugs happen a lot more in Python. Rs copy on write, for example makes it a much more functional language without unintended side effects- Python is very inconsistent in that regard, with different variable types and data structures behaving entirely different in identical situations.