In Pandas or Polars-Python, we can loc a value by using iloc
loc
or [1,2]
. How could we do the same thing in Polars with Rust?
Asked
Active
Viewed 2,146 times
2

Hakase
- 211
- 1
- 12
1 Answers
0
Here is a guide explaining this in great detail: https://pola-rs.github.io/polars-book/user-guide/indexing.html
In short, Polars uses direct indexing in lieu of loc
/iloc
.
The guide lists a lot of helpful examples.

Anton Shpigunov
- 184
- 2
- 8
-
1The example is python. How would you do something like df[:2] in pure Rust? – Anatoly Bugakov May 03 '22 at 17:07