WICHTIG: Der Betrieb von goMatlab.de wird privat finanziert fortgesetzt. - Mehr Infos...

Mein MATLAB Forum - goMatlab.de

Mein MATLAB Forum

 
Gast > Registrieren       Autologin?   

Partner:




Forum
      Option
[Erweitert]
  • Diese Seite per Mail weiterempfehlen
     


Gehe zu:  
Neues Thema eröffnen Neue Antwort erstellen

Merging two time series

 

liso
Forum-Anfänger

Forum-Anfänger


Beiträge: 39
Anmeldedatum: 12.07.08
Wohnort: ---
Version: ---
     Beitrag Verfasst am: 19.01.2013, 09:17     Titel: Merging two time series
  Antworten mit Zitat      
Hi all

You may help with the following question: I have two files with data series in different time scales. Data 1 are time series recorded with 10 Hz (the attached files contain the data from subject 1 and 2). Data 2 are behavioral data (the attached file contains the data from both subjects 1 and 2 together in one file).

How could these three files be merged so that all subjects and all information is aligned in one file?

I attached the input files, and an output file that should be created, i.e. how it could look like. Shown are just the beginnings of large files and 2 out of 20 subjects.

Many thanks for your ideas!
Liso

Output.xls
 Beschreibung:
Output, how the merged file could look like.

Download
 Dateiname:  Output.xls
 Dateigröße:  137 KB
 Heruntergeladen:  316 mal
Data2_Subject1-2.xls
 Beschreibung:
Data 2 are behavioral data. Subject 1 and 2-

Download
 Dateiname:  Data2_Subject1-2.xls
 Dateigröße:  25.5 KB
 Heruntergeladen:  347 mal
Data1_Subject2.xls
 Beschreibung:
Data 1 are time series recorded with 10 Hz. Subject 2.

Download
 Dateiname:  Data1_Subject2.xls
 Dateigröße:  44 KB
 Heruntergeladen:  307 mal
Data1_Subject1.xls
 Beschreibung:
Data 1 are time series recorded with 10 Hz. Subject 1.

Download
 Dateiname:  Data1_Subject1.xls
 Dateigröße:  51 KB
 Heruntergeladen:  357 mal
Private Nachricht senden Benutzer-Profile anzeigen


Seban
Forum-Meister

Forum-Meister


Beiträge: 600
Anmeldedatum: 19.01.12
Wohnort: ---
Version: ab R2014b
     Beitrag Verfasst am: 19.01.2013, 10:59     Titel:
  Antworten mit Zitat      
Hi,

You can use xlsread to save the file contents to cell-arrays.
Code:
[num, txt, raw]  = xlsread(filename, sheet, xlRange);


Afterwards rearrange the contents of these arrays and write them into a new xls file with xlswrite.

http://www.mathworks.de/de/help/matlab/ref/xlsread.html
http://www.mathworks.de/de/help/matlab/ref/xlswrite.html
_________________

Richtig fragen
Debugging
Private Nachricht senden Benutzer-Profile anzeigen
 
liso
Themenstarter

Forum-Anfänger

Forum-Anfänger


Beiträge: 39
Anmeldedatum: 12.07.08
Wohnort: ---
Version: ---
     Beitrag Verfasst am: 20.01.2013, 00:31     Titel:
  Antworten mit Zitat      
Hi

Thanks for the xlsread and xlswrite links. However, I am still struggling how to rearrange the arrays. How can the two time scales be aligned?

myna thanks, Liso
Private Nachricht senden Benutzer-Profile anzeigen
 
Neues Thema eröffnen Neue Antwort erstellen



Einstellungen und Berechtigungen
Beiträge der letzten Zeit anzeigen:

Du kannst Beiträge in dieses Forum schreiben.
Du kannst auf Beiträge in diesem Forum antworten.
Du kannst deine Beiträge in diesem Forum nicht bearbeiten.
Du kannst deine Beiträge in diesem Forum nicht löschen.
Du kannst an Umfragen in diesem Forum nicht mitmachen.
Du kannst Dateien in diesem Forum posten
Du kannst Dateien in diesem Forum herunterladen
.





 Impressum  | Nutzungsbedingungen  | Datenschutz | FAQ | goMatlab RSS Button RSS

Hosted by:


Copyright © 2007 - 2025 goMatlab.de | Dies ist keine offizielle Website der Firma The Mathworks

MATLAB, Simulink, Stateflow, Handle Graphics, Real-Time Workshop, SimBiology, SimHydraulics, SimEvents, and xPC TargetBox are registered trademarks and The MathWorks, the L-shaped membrane logo, and Embedded MATLAB are trademarks of The MathWorks, Inc.