Arrange data of an array in certain order.

2 visualizaciones (últimos 30 días)
arifahazwani AY
arifahazwani AY el 12 de Mzo. de 2020
Respondida: Piyush Lakhani el 12 de Mzo. de 2020
Hi, currently I have a datasheet in alphabetic order (3 column X, Y and Z for each variable). how I want to rearrange the datasheet in certain specific order.?
Attached herewith the txt.file and xlsx.file.
The order in the datasheet is
C1, C2....FAM, FCC,...
However, i need to arrange it
FM2,FCC,..C1,...
Thank you in advance!

Respuestas (1)

Piyush Lakhani
Piyush Lakhani el 12 de Mzo. de 2020
Hi,
First read the text file and X,Y,Z data for indiviual variables.
D=xlsread('DynamicDW.xlsx')
C1=D(:,[1:3]);
C2=D(:,[4:6]);
%Like wise all the variables
FAM=D(:,[start:end])
% Then
Rearrage=[FM2 FCC C1 C2 ] %Write all variables

Categorías

Más información sobre MATLAB en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by