# Is there an equivalent of eachindex() for DataFrames?

**URL:** https://discourse.julialang.org/t/is-there-an-equivalent-of-eachindex-for-dataframes/88945
**Category:** General Usage
**Tags:** question, dataframes, type-stability
**Created:** [October 19, 2022, 7:17am UTC](https://discourse.julialang.org/t/is-there-an-equivalent-of-eachindex-for-dataframes/88945 "2022-10-19T07:17:21Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![rafael.guerra](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rafael.guerra/32/216610_2.png) [@rafael.guerra](https://discourse.julialang.org/u/rafael.guerra)
#### Post date: [October 19, 2022, 7:52am UTC](https://discourse.julialang.org/t/is-there-an-equivalent-of-eachindex-for-dataframes/88945/2 "2022-10-19T07:52:52Z")

</div>

One option might be:

```julia
for i in 1:nrow(df), j in 1:ncol(df)
    df[i,j] = "$(df[i,j]) sold out"
end

```

---

_[View the full topic](https://discourse.julialang.org/t/is-there-an-equivalent-of-eachindex-for-dataframes/88945)._
