# How do I create a first examples subset of a dataframe?

**URL:** <https://discourse.julialang.org/t/how-do-i-create-a-first-examples-subset-of-a-dataframe/64957>\
**Category:** New to Julia\
**Created:** [July 20, 2021, 1:18am UTC](https://discourse.julialang.org/t/how-do-i-create-a-first-examples-subset-of-a-dataframe/64957 "2021-07-20T01:18:30Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![banksiaboy](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/banksiaboy/32/27032_2.png) [@banksiaboy](https://discourse.julialang.org/u/banksiaboy)\
**Post date:** [July 20, 2021, 1:18am UTC](https://discourse.julialang.org/t/how-do-i-create-a-first-examples-subset-of-a-dataframe/64957/1 "2021-07-20T01:18:30Z")

</div>

I have a DataFrame with columns `[:species :jpg_url]`.  
There can be many jpegs associated with each species. How do I get a subset of my DataFrame with the same columns and just the first picture associated with each species?

---

<div class="post-metadata">

**Author:** ![DataFrames](https://avatars.discourse-cdn.com/v4/letter/d/e19b73/32.png) [@DataFrames](https://discourse.julialang.org/u/DataFrames)\
**Post date:** [July 20, 2021, 4:16am UTC](https://discourse.julialang.org/t/how-do-i-create-a-first-examples-subset-of-a-dataframe/64957/2 "2021-07-20T04:16:13Z")

</div>

```julia
unique(df, :species)

```
