09-03-2024 02:03 PM
Hi everyone
I am new to Labview and faced with a challenge. I have a txt data whihc is in a single line format and I am looking at converting it into csv format for easy manipulation in python.
Attached is a screenshot of how the data looks like.
09-03-2024 02:14 PM - edited 09-03-2024 02:14 PM
Are you asking how to change the file suffix from a TXT file to a CSV? I'd think it's as simple as that.
Load your VI and show us what you've tried so far...
09-03-2024 02:41 PM
Hi Erick This is the bit I have tried so far. That's just reading the txt file. When i load it in Jupyter notebook, it comes as just a single line which causes the software to crash because it has over 32 million characters. I want to introduce a delimeter to separate the number which will make it easier for me to manipute with python
09-03-2024 02:55 PM
Two things that immediately jump out at me.
As for your data delimiter, it looks like a space or possibly a tab between values. If you download Notepad++, that is an excellent program when looking for delimiters like spaces, commas, carriage returns, line feeds, etc. It can do much, much more than that. I use it quite a bit.
See what you can dig up and come back to us.
09-03-2024 03:00 PM
Try using a function READ DELIMITED Spreadhseet.
Use the character delimiter on the input DELIMITER it will return a 2d array with all the lines of data, then use a function index array to select wich of the lines you want to pass to your python code.
09-03-2024 03:07 PM
Thanks ROtake
I will give it a shot