save curve data in excel or .txt into specified path
![satya swaroop](https://us.v-cdn.net/6038102/uploads/defaultavatar/nLP0QHCLH24WL.jpg)
Hi
R = omlfilename()
R = omlfilename('fullpath')
close all;
clear all;
clc;
c1=readvector('.odb','loadstep2:','RF-Reaction force (PART-1-1)','N1','Z')
plot(c1)
c2=readvector('.odb','loadstep2:','Displacement (PART-1-1)','N1','Z')
c=plot(-c2,-c1)
R=xlswrite('test.csv',[c1; c2])
i am generating a curve with this code
now i want to save or export the data points of plotted curved in the form of xlsx or txt in a specified path
how can i do this
appreciate your comments
thanks
Answers
-
Hi Satya,
There are some ways to do that, the easiest one would be: After que command 'c=plot(-c2,-c1)' you can break the line and change a bit your code:
c=plot(-c2,-c1)
fpath = 'C:\Users\jmarabisa\Desktop\';
R=xlswrite([fpath 'test.csv'],[c1; c2]);'fpath' is the variable that you'll be referencing your desired path to save the xlsx file.
Hope it helps you,
João.
0 -
Hello
João MarabisaThank you very much it worked0