# How to store certain indices in point set or a matrix?

**URL:** https://discourse.itk.org/t/how-to-store-certain-indices-in-point-set-or-a-matrix/3459
**Category:** Uncategorized
**Created:** [September 13, 2020, 4:56pm UTC](https://discourse.itk.org/t/how-to-store-certain-indices-in-point-set-or-a-matrix/3459 "2020-09-13T16:56:49Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![unicorn](https://discourse.itk.org/letter_avatar_proxy/v4/letter/u/35a633/32.png) [@unicorn](https://discourse.itk.org/u/unicorn)
#### Post date: [September 13, 2020, 4:56pm UTC](https://discourse.itk.org/t/how-to-store-certain-indices-in-point-set-or-a-matrix/3459/1 "2020-09-13T16:56:49Z")

</div>

I want to extract certain indices of segmentation from each slice of the image and store it in a point set or a matrix(I’m not sure which one to use). Upon that, I would like to perform singular value decomposition.

How should I do this?

Note: I have already extracted the index values but how to store them all together?

---

<div class="post-metadata">

### Author: ![dzenanz](https://discourse.itk.org/user_avatar/discourse.itk.org/dzenanz/32/1093_2.png) [@dzenanz](https://discourse.itk.org/u/dzenanz)
#### Post date: [September 14, 2020, 4:40pm UTC](https://discourse.itk.org/t/how-to-store-certain-indices-in-point-set-or-a-matrix/3459/2 "2020-09-14T16:40:05Z")

</div>

This [example](https://itk.org/ITKExamples/src/Core/Common/CreateAPointSet/Documentation.html) how you can create a point set.

What are you trying to accomplish by SVD?
