'Add channels to / edit existing tdms files?

I have a naive question but did not manage to find a clear answer. I have some .tdms files with channels of data. I would like to add additionnal channel of data in this tdms file (for example in Python take 2 existing channels and go: "newChannel = channel_1 + channel_2" and add this newChannel to my tdms file).

I did not find any way to edit / add data to a tdms file, is that even possible ? For now I just create .h5 files for each tdms file (on which I can add data), but they take more space than the .tdms for the same amount of data (that's why I'm interested to work directly on the .tdms).

Thanks



Solution 1:[1]

Do you want to update that TDMS file with LabVIEW or Python ? With Labview you can simply open the file and write your new data in your new channel using the TDMS write VI function :

Write in TDMS with LabVIEW

If you want to edit your TDMS files with python you should try https://pypi.org/project/npTDMS/ (never tried it myself as it's so well integrated in LabVIEW)

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 ti7