I would like to get the volume waveform data and convert that data to CSV format and retrieve it.
However, it seems that file out dat can only be converted to .dat or .txt.
I could not successfully extract the exported .txt file as a csv.
Doesn’t it support CSV format export yet?
Or is there a technique for writing it out that neatly keeps the rows and columns?
If you feed a table DAT to the fileout DAT you can save as CSV - you just have to change your file extension.
Thank you for your response!
I was able to confirm that it can be expanded as a csv when I did file out dat from table dat.
However, I couldn’t do what I wanted to do because I don’t know how to convert from chop to dat to table dat.
Do I need to write a script?
fileout_csv.toe (16.3 KB)
Take a look at this example - you just need to change the file extension to csv on the fileout DAT. You can then pulse the Write File
parameter to write that csv to disk.
mr-edit-fileout_csv.toe (16.3 KB)
It’s done! Cheers!
I was mistaken that the common > edit extension should be changed to csv.
Thank you so much for your prompt response.
Reviving Super old thread, but am I not sure if I am missing something super obvious or it’s possibly a bug.
I want to save my tables as CSV
I got table
>> fileout
(with extension as CSV)
Yet when I bring it in with filein
you can see it’s missing the columns. When I open the file in a text editor I can see it’s missing comas too.
Am I missing anything?
Thanks again!
Hmmm - interesting. I’m getting the same result. This might be worth moving to bugs - or posting there as well.
Sorry to revive the old thread but found some interesting behavior and thought it would be useful to share.
Similar to tellart if I save via the “Write File” button on the I get tab delineated values.
If however I call “op(‘fileout1’).save(‘data.csv’)” from a script I get comma delineated values.
Might be useful to anyone who comes across this thread with the same issue as I did.
–Hank
Thanks Hank, running save() from a script worked for me as well. It seems the “Write File” button is not working properly.
I have an additional question. I checked my saved csv file and the delimiter was tab. Is there any way to change the delimiter to a comma?
mhank above mentioned that if you use the python command to save out then it is comma separated.
Thanks for letting me know.
Sorry, it was written just right above. I had overlooked it.
Let me know of that still works and is a success for you.
It works!!
When I save from script, my csv file was saved with commas.
I said it worked, but a few problems remained.
When I reopened the saved toe file, no data was entered into File Out DAT until the write button was pushed.
I have attached a toe file that easily shows the problem.
CSV_output_test.toe (10.3 KB)
The problem is that null1 is not connected to fileout1 in the file you sent. The ‘write’ parameter is in ‘constant mode’ but it should be in ‘expression mode’ to use the expression you added to connect null1 to fileout1.
Alternatively you could export the CHOP channel v1 to the write parameter if you didn’t want to use that python expression.
Read more on parameter modes here:
Sorry ben, my explanation was not sufficient.
In CSV_output_test.toe, I understand that chopexec1 calls the save method of fileout1 when null1 value changes, so there is no need to connect null1 and fileout1 directly, is that correct?
-
What I want to do
Output a comma delimited csv file -
As it is now (my understanding)
– When I press the write button on fileout, it outputs a tab-delimited csv file.
– To output a comma delimited csv file, it is necessary to call the save method from script. (i.e. op(‘fileout1’).save(‘data.csv’)) -
Problem
– Calling the save method from script (at chopexec1 in CSV_output_test.toe) does not work until the fileout’s write button is pressed in any mode. (Although the data actually be written out, an empty csv file is output because the data entered in the fileout is not reflected.)
– Once the fileout write button is pressed, the save method from script works from then on.
– However, when the toe file is reopened, the save method does not work again. -
Temporary solution
Export the value of null1 to fileout1 write.
Only the first time the button is pressed, fileout outputs an empty csv file, but the second and subsequent times it outputs correctly.
I would like to know if there is a better way.
Sorry, I only checked the datout.csv and did not notice the data.csv was empty.
This is happening because after opening the File Out DAT as not cooked yet. Since you only require the comma delimited csv file, you do not need the File Out DAT at all, you can write the file directly from chopto2 by changing the save method from script to be
op('chopto2').save(filename)
This works more reliably, it should cause no problems.
CSV_output_test.1.toe (10.1 KB)
Tested using 2022.28040
Oh!
This is exactly what I was looking for!!
Thank you so much.
Hello, sorry I’m replying to an old chat!
But I was wondering, I would like to save the RGB values in a CSV file of a sequence. But I don’t manage to save a working CSV.
Can maybe someone help? I would hope it would be a quick fix, for the pros!
CSV_output_test_Naomi.toe (6.4 KB)