Real time data transfer from excel to Matlab
Ältere Kommentare anzeigen
I've got a problem: i want to update real time data from an excel file to Matlab to be able to make a real time plot with Matlab. I think that I've got to work with an actxserver, but I'm not sure.
This is what i've got:
>>clear all
>>excelapp = actxserver('Excel.Application'); >>wkbk=excelapp.Workbooks; >>wdata=wkbk.Open('d:realtime_data.xls');
>>sheets=wdata.Sheets; >>sheet22=sheets.Item('dataset22'); >>range = sheet22.get('Range', 'B4', 'U4'); >>range.value
The range B4:U4 in excel will be updated every second. I’ve got the question if this is the best way to get the real time data in Matlab, or is there a better method to do this?
Thanks!
Dental
1 Kommentar
Gerd
am 14 Jun. 2011
Hi Dental,
in our company we used DDE communication pretty often. Since new technology is coming up we switched to COM. I think this is an easy approch to get your "real time data" into Matlab.
Please have a look into the HELP under
Getting Started with COM
Cheers Gerd
Antworten (1)
KAUSTUBH ISADKAR
am 28 Dez. 2018
0 Stimmen
Hii,
I am new to matlab trying to get excel sheet data to Matlab
Can you explain the code you have generated
"sheets=wdata.Sheets; >>sheet22=sheets.Item('dataset22'); >>range = sheet22.get('Range', 'B4', 'U4'); >>range.value"
I am confused with Sheet22=sheets.Item('dataset22')
what is its syntax?
thanks for your help!
regards,
Kaustubh
Kategorien
Mehr zu Spreadsheets finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!