# Convert fcsv files into nts files

**URL:** <https://discourse.slicer.org/t/convert-fcsv-files-into-nts-files/21451>\
**Category:** Support\
**Tags:** markups-fiducials\
**Created:** [January 13, 2022, 8:01pm UTC](https://discourse.slicer.org/t/convert-fcsv-files-into-nts-files/21451 "2022-01-13T20:01:29Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![jusopar](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/jusopar/32/10144_2.png) [@jusopar](https://discourse.slicer.org/u/jusopar)\
**Post date:** [January 13, 2022, 8:01pm UTC](https://discourse.slicer.org/t/convert-fcsv-files-into-nts-files/21451/1 "2022-01-13T20:01:29Z")

</div>

Is it possible to export landmarks as nts files? If not, is there a way to convert fcsv files into nts files?

Operating system: Windows  
Slicer version: 4.11.20210226  
Expected behavior:  
Actual behavior:

---

<div class="post-metadata">

**Author:** ![muratmaga](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/muratmaga/32/3622_2.png) [@muratmaga](https://discourse.slicer.org/u/muratmaga)\
**Post date:** [January 13, 2022, 8:14pm UTC](https://discourse.slicer.org/t/convert-fcsv-files-into-nts-files/21451/2 "2022-01-13T20:14:10Z")

</div>

Is this the nts format you are referring to? [readland.nts: Read landmark data matrix from nts file in geomorph: Geometric Morphometric Analyses of 2D/3D Landmark Data](https://rdrr.io/cran/geomorph/man/readland.nts.html)

You can read this previous [thread related getting data into MorphoJ format](https://discourse.slicer.org/t/slicermorph-paper/18751/13) and perhaps modify [this example code](https://gist.github.com/smrolfe/f6ea90d9ff59bb306b8127b7342b4f6e) to make it work for nts format.

Short answer is there is no immediate way of converting fcsv to nts, without a script.

---

<div class="post-metadata">

**Author:** ![jusopar](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/jusopar/32/10144_2.png) [@jusopar](https://discourse.slicer.org/u/jusopar)\
**Post date:** [January 13, 2022, 8:20pm UTC](https://discourse.slicer.org/t/convert-fcsv-files-into-nts-files/21451/3 "2022-01-13T20:20:09Z")

</div>

Yes, that’s the nts format I referred to! I am planning to use it in geomorph indeed.

I believe this code will be of a great help! Thank you @muratmaga !

---

<div class="post-metadata">

**Author:** ![muratmaga](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/muratmaga/32/3622_2.png) [@muratmaga](https://discourse.slicer.org/u/muratmaga)\
**Post date:** [January 13, 2022, 10:16pm UTC](https://discourse.slicer.org/t/convert-fcsv-files-into-nts-files/21451/4 "2022-01-13T22:16:10Z")

</div>

İf you are going to use with geomorph, no need to convert fcsvs to nts.  
Use the utility functions in SlicerMorphR  
`devtools::install_github("SlicerMorph/SlicerMorphR")` and use the example code to import data into R  
Much easier!

---

<div class="post-metadata">

**Author:** ![jusopar](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/jusopar/32/10144_2.png) [@jusopar](https://discourse.slicer.org/u/jusopar)\
**Post date:** [January 13, 2022, 10:59pm UTC](https://discourse.slicer.org/t/convert-fcsv-files-into-nts-files/21451/5 "2022-01-13T22:59:35Z")

</div>

Perfect! Thank you so much!
