Real time data transfer from excel to Matlab
Afficher commentaires plus anciens
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 commentaire
Gerd
le 14 Juin 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
Réponses (1)
KAUSTUBH ISADKAR
le 28 Déc 2018
0 votes
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
Catégories
En savoir plus sur Spreadsheets dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!