# Help with getting the stimuli name/path

**URL:** <https://discourse.psychopy.org/t/help-with-getting-the-stimuli-name-path/33021>\
**Category:** Builder\
**Created:** [January 30, 2023, 6:00pm UTC](https://discourse.psychopy.org/t/help-with-getting-the-stimuli-name-path/33021 "2023-01-30T18:00:16Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Easyteam](https://avatars.discourse-cdn.com/v4/letter/e/b5a626/32.png) [@Easyteam](https://discourse.psychopy.org/u/Easyteam)\
**Post date:** [January 30, 2023, 6:00pm UTC](https://discourse.psychopy.org/t/help-with-getting-the-stimuli-name-path/33021/1 "2023-01-30T18:00:16Z")

</div>

I am new to Psychopy and coding, I have an experiment with different 10 image stimuli, I am generating tens of data per each stimuli, i saved the data in another excel file but I will need the name of the image/stimuli in another column to know which data is gotten from which image.

I tried adding a column with image.name but its just listing ‘image’ instead and not the name/path of each of the stimuli.

I need help with this.

---

<div class="post-metadata">

**Author:** ![JensBoelte](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.psychopy.org/jensboelte/32/9060_2.png) [@JensBoelte](https://discourse.psychopy.org/u/JensBoelte)\
**Post date:** [January 30, 2023, 6:24pm UTC](https://discourse.psychopy.org/t/help-with-getting-the-stimuli-name-path/33021/2 "2023-01-30T18:24:03Z")

</div>

Hello Easyteam

did you take a look at the csv-file? The columns of your Excel-file used to present the stimuli will be save to the csv-file.

BTW, Peirce, J. W., Hirst, R. J. & MacAskill, M. R. (2022). [Building Experiments in PsychoPy. 2nd Edn](https://uk.sagepub.com/en-gb/eur/building-experiments-in-psychopy/book273700) London: Sage is an excellent source to get started with PsychoPy.

Best wishes Jens

---

<div class="post-metadata">

**Author:** ![Easyteam](https://avatars.discourse-cdn.com/v4/letter/e/b5a626/32.png) [@Easyteam](https://discourse.psychopy.org/u/Easyteam)\
**Post date:** [January 30, 2023, 6:33pm UTC](https://discourse.psychopy.org/t/help-with-getting-the-stimuli-name-path/33021/3 "2023-01-30T18:33:50Z")

</div>

Thank you for your reply, there is the column in the csv file, but I have two csv files, the normal output csv from psychopy and another csv I created myself, I want the Image names column on the csv file I created.

---

<div class="post-metadata">

**Author:** ![JensBoelte](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.psychopy.org/jensboelte/32/9060_2.png) [@JensBoelte](https://discourse.psychopy.org/u/JensBoelte)\
**Post date:** [January 31, 2023, 8:30am UTC](https://discourse.psychopy.org/t/help-with-getting-the-stimuli-name-path/33021/4 "2023-01-31T08:30:05Z")

</div>

Hello Easyteam

so how do you try to add the image-column to your self-created csv-file?

Best wishes Jens

---

<div class="post-metadata">

**Author:** ![Easyteam](https://avatars.discourse-cdn.com/v4/letter/e/b5a626/32.png) [@Easyteam](https://discourse.psychopy.org/u/Easyteam)\
**Post date:** [January 31, 2023, 11:18am UTC](https://discourse.psychopy.org/t/help-with-getting-the-stimuli-name-path/33021/5 "2023-01-31T11:18:14Z")

</div>

Thank you, I used “ws.write(row, 1, str(image.name))”, image is the name of the component.

Is it possible to have another column in the original csv file showing the image stimuli names again? I already have the default column but I need another column, I tried “thisExp.addData(‘images’, image.name)” but its just giving the name of the component which is “image” and not the name of each of the image stimuli.

---

<div class="post-metadata">

**Author:** ![JensBoelte](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.psychopy.org/jensboelte/32/9060_2.png) [@JensBoelte](https://discourse.psychopy.org/u/JensBoelte)\
**Post date:** [January 31, 2023, 11:46am UTC](https://discourse.psychopy.org/t/help-with-getting-the-stimuli-name-path/33021/6 "2023-01-31T11:46:13Z")

</div>

Hello,

I have a column in an Excel-file called imageName which specifies the image presented in a trial. When I add

```auto
thisExp.addData('FileName', imageName)

```

in a code-component in the End routine tab I get an extra column in the PsychoPy data-file called FileName which lists the filenames of the images displayed.

Best wishes Jens

---

<div class="post-metadata">

**Author:** ![Easyteam](https://avatars.discourse-cdn.com/v4/letter/e/b5a626/32.png) [@Easyteam](https://discourse.psychopy.org/u/Easyteam)\
**Post date:** [January 31, 2023, 12:16pm UTC](https://discourse.psychopy.org/t/help-with-getting-the-stimuli-name-path/33021/8 "2023-01-31T12:16:45Z")

</div>

Thank you greatly, that works
