This also works from a dos() command in matlab in case you want to call the simulator to operate on the netlist.txt which you can get by copying the netlist it makes after running the schematic in the GUI and pasting it into a text file.
I tried this in the QucsStudio window using octave with a single line. It didn’t work unless I put the whole thing in ‘ single quotes and you need to use ” double quotes around your paths if they have spaces in the names. To get the netlist I run the schematic and then it appears in the .qucs folder, you can also go to ->Simulation ->Show last netlist and then save it to the location of your choice.
For example, this directly works for me, I pasted it from my one line octave script which also works in matlab:
the data in .dat are saved in a binary format which requires the use of the octave post processing scripts provided in the octave folder, a few tweaks are needed to use them in matlab due to how it opens the binary files.